|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2015-11-07 16:46 UTC] marcosptf at yahoo dot com dot br
[2015-11-10 09:13 UTC] m dot subotovic at gmail dot com
[2016-10-15 23:06 UTC] kalle@php.net
-Status: Open
+Status: Wont fix
[2016-10-15 23:06 UTC] kalle@php.net
|
|||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Dec 18 09:00:01 2025 UTC |
Description: ------------ Fatal error: Allowed memory size of X bytes exhausted (tried to allocate 4294967296 bytes) The error above is being shown when using mssql_fetch_batch on two different connections. Look at the test script example. Test script: --------------- <?php function fetchAssoc($link) { $res = mssql_fetch_assoc($link); if ($res === false) { if (mssql_fetch_batch($link) > 0) { $res = mssql_fetch_assoc($link); } } return $res; } $link1 = mssql_connect('host', 'user', 'pwd'); mssql_select_db('db', $link1); $link2 = mssql_connect('host', 'user', 'pwd'); mssql_select_db('db', $link2); $result1 = mssql_query("SELECT TOP 2 * FROM table", $link1, 1); while ($row1 = fetchAssoc($result1)) { echo "Row from 1 result\n"; $result2 = mssql_query("SELECT TOP 2 * FROM table2", $link2); while ($row2 = fetchAssoc($result2)) { echo "Row from 2 result\n"; } } echo "Done"; Expected result: ---------------- Row from 1 result Row from 2 result Row from 2 result Row from 1 result Row from 2 result Row from 2 result Done Actual result: -------------- Row from 1 result Row from 2 result Row from 2 result Fatal error: Allowed memory size of X bytes exhausted (tried to allocate 4294967296 bytes)