|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #903 odbc_result() yields "Memory allocation failure, SQL state S1001 in SQLGetData"
Submitted: 1998-11-06 11:11 UTC Modified: 1999-02-16 04:44 UTC
From: peter dot lerner at bayreuth dot baynet dot de Assigned: kara (profile)
Status: Closed Package: ODBC related
PHP Version: 3.0 Latest CVS (06/11/1998) OS: Linux 2.0.35
Private report: No CVE-ID: None
 [1998-11-06 11:11 UTC] peter dot lerner at bayreuth dot baynet dot de

i use adabas ...
 Kernel Version  'KERNEL 10.05.04     DATE 1998-07-28'
 RTE    Version  'RTE 10.05.01  LINUX DATE 1998-04-27'
 Control Version 'CONTROL 10.05.02    DATE 1998-07-03'
... and php3/3.06-dev as apache-modul, apache 1.3.3,
linux 2.0.35, etc ...

i get the following strange error while trying to display
a gif-picture out of a LONG row from adabas.

Warning: SQL error: [SOFTWARE AG][ODBCLIB A]Memory allocation failure.,
SQL state S1001 in SQLGetData in
/usr/local/apache/htdocs/ivdm/blau/haendler/display.php3 on line 14

i use the php-program named 'display.php3', shown in the following.
'display.php3' is simply derived from the odbc-testsuite delivered
with php3 in the 'tests' directory.

btw ... the testsuite shows the same problem as my code.
and i am not quite sure, if the problem is php3/odbc or
adabas/odbc related.

with Adabas-WebDB or tkquery i get some contents out of my
LONG row, but not with php3 .... i did not yet try it with e-sqlc ...

perhaps the problem is php-related, or could be solved on the
php-side ... i can provide you with the latest adabas odbc-ref-manual
if you need any info, but be prepared its big ... perhaps adabas
again has some %?/$%-standard extensions, that you did not yet
take care off ...

------- detail.php3 -------

//echo "uid = " . $uid . "<br>\n";

if($conn = odbc_connect("xxx", "ABC", "GUESS"))
  if($result = odbc_exec($conn, "SELECT logo FROM haendler WHERE uid = '$uid'"))
    odbc_binmode($result, 0);
    odbc_longreadlen($result, 0);
    if(odbc_fetch_row($result, 1))
      header("content-type: image/gif");
>      odbc_result($result, 1);    // here is the problem !!
echo "ups. ;=)";

------------- schnapp ------------

peter lerner


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [1999-02-16 04:44 UTC] kara
Does this problem still exist with 3.0.6 / latest CVS? 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Sat Jan 25 23:01:24 2020 UTC