dou6495 2013-05-14 17:33
浏览 51

php sybase允许的内存大小耗尽?

I'm getting this problem while trying to run any query against Sybase from php:

  • PHP 5.4.3 (cgi-fcgi) (built: May 9 2013 17:03:23)
  • built --with-sybase-ct=/path/to/freetds
  • code:

    <?php
    $con = sybase_connect('server', 'user', 'pwd'); //connects fine
    $q = sybase_query("select col=1", $con);        //error here, regardless of SQL
    ?>

  • Output:
    Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 30064771074 bytes)

Any ideas ?

  • 写回答

1条回答 默认 最新

  • douxu0550 2013-05-14 17:40
    关注

    try to add this to your code :

    <?php
        ini_set("memory_limit","128M");
        $con = sybase_connect('server', 'user', 'pwd'); //connects fine
        $q = sybase_query("select col=1", $con);        //error here, regardless of SQL
        ?>
    
    评论

报告相同问题?