0

Hi All,

I am having contsantly getting the following error:

PHP Fatal error: Out of memory (allocated 4295491584) (tried to allocate 8589934593 bytes)

the line its complaining about is as following hilighted in bold:

<?php
$link = @sybase_connect('****', '***', '****')
        or die("Could not connect !");
echo "Connected successfully";

$sql = "SELECT id_key, nm_value, dt_create
          FROM MERLIN_PROPERTIES";

echo "<table border='1' width='100%' cellspacing=0 cellpadding=0>";
echo "   <tr bgcolor='lightblue'>";
echo "      <td><b>ID KEY</b></td>";
echo "      <td><b>NM VALUE</b></td>";
echo "      <td><b>DT CREATE</b></td>";
echo "   </tr>";

[B]$sql_result = sybase_query($sql,$link);[/B]

Any help would be very much appreciated. Many thanks

Shuel

3
Contributors
2
Replies
4
Views
8 Years
Discussion Span
Last Post by mypaper
0

If you are working with a huge number of records, maybe sybase is trying to build a table in memory to hold all the results and it's running out of space. If that is a possibility, then you might want to try changing your query as an experiment to limit the number of records by something like "...and id_key < 1000" (based on looking at the keys that you have and picking one that is pretty low in the range). If that works, then you could try increasing the amount of memory (see the post ) and/or by process the input in stages by key range or alphabetically by the name or by date ranges.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.