Problem about OCI functions

From: Date: Thu, 19 Oct 2000 04:25:32 +0000
Subject: Problem about OCI functions
Groups: php.dev 
Request: Send a blank email to php-dev+get-35483@lists.php.net to get a copy of this message
Dear All, I have a little problem when I using OCI functions. I have copy a sample code from the PHP manual using OCI and create the tables in my Oracle8i which are needed when running the program. The program can run properly sometimes, and I also get the error ORA-24327 sometimes. I hope someone can help me the settle it down. Following is the code: <?php 3 /* OCIDefineByPos example thies@digicol.de (980219) */ 4 5 $conn = OCILogon("scott","tiger"); 6 7 $stmt = OCIParse($conn,"select empno, ename from emp"); 8 9 /* the define MUST be done BEFORE ociexecute! */ 10 11 OCIDefineByName($stmt,"EMPNO",&$empno); 12 OCIDefineByName($stmt,"ENAME",&$ename); 13 14 OCIExecute($stmt); 15 16 while (OCIFetch($stmt)) { 17 echo "empno:".$empno."\n"; 18 echo "ename:".$ename."\n"; 19 } 20 21 OCIFreeStatement($stmt); 22 OCILogoff($conn); 23 ?> Any of your help will be very appreciated. Many thx in advance. Best Regards, Axl

« previous php.dev (#35483) next »