| 
        php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
 PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits             
             [1999-06-20 20:08 UTC] jim at cvs dot php dot net
  [1999-06-20 20:08 UTC] jim at cvs dot php dot net
  | 
    |||||||||||||||||||||||||||
            
                 
                Copyright © 2001-2025 The PHP GroupAll rights reserved.  | 
        Last updated: Tue Nov 04 07:00:01 2025 UTC | 
I'm trying to use PHP3 (CGI) to connect to an Oracle database. I've compiled version 3.0.9 on a RH Linux (5.1) box (gcc), and an HP-UX 10.20 box (HP AN$I C compiler), both of which have Oracle 8.0.5 installed on them. The configure and make go flawlessly (using --with-oracle on the configure with environment var $ORACLE_HOME set to my oracle home directory) and I get a php binary which executes the included "date.php3" and "dir.php3" example scripts correctly. The problem is that when I create a script that tries to connect to oracle, I get the following error: **************************ERROR TEXT********************************** Call to unsupported or undefined function ora_login() in <b>../oratest.php3</b> on line <b>6</b><br> **************************ERROR TEXT********************************** The script I'm using follows. (I'm using the default php3.ini file) **************************SCRIPT TEXT********************************** <? // PHP3 Oracle test putenv("ORACLE_SID=ORACLE"); putenv("ORACLE_HOME=/opt/app/oracle/product/8.0.5"); $dbConn = ora_login("testuser/testuser@tesdb.world",""); $ora1 = ora_open($dbConn); result = ora_parse($ora1, 'select * from test_table', 0); result = ora_exec($ora1); result = ora_fetch($ora1); $ncols = ora_numcols($ora1); $nrows = ora_numcols($ora1); printf("Result size is $ncols cols by $nrows rows.<br>"); for ($i=0; $i<$ncols; $i++) { printf("col[%s] = %s type[%d] = %s<br>", $i, ora_columnname($ora1, $i), $i, ora_columntype($ora1, $i)); } for ($j=0; $j<$nrows; $j++) { for ($i=0; $i<$ncols; $i++) { $col = ora_getcolumn($ora1, $i); printf("val[%d, %d] = %s * ", $j, $i, ora_getcolumn($ora1, $i); } printf("<br>"); } ?>