Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

not a valid oci8 statement resource

763719Mar 30 2010 — edited Apr 12 2010
I've been grappling this problem sometime, google doesn't help because all the results I get are pages with the same error.

Warning: oci_fetch(): 3 is not a valid oci8 statement resource in /home/dsk10/ugrad/bejhan/web_docs/facttable.php on line 21

Line 21 is: while(oci_fetch($SQL)) {

My loop functions correctly and fetches the results properly though. Here is my connect and creation of the statement:

$c = oci_connect("bejhan", "******");
$SQL = oci_parse($c, "SELECT TIMETRANSACTIONID, TO_CHAR(TDATETIME, 'YYYY-MM-DD HH24:MI:SS') AS PHPDATE, DURATION, TIMECODEDEFID, TEAM, MATERIALTYPE FROM c391.TimeTransactionData78 WHERE ROWNUM < 10 ORDER BY TDATETIME");
oci_execute($SQL);

When I run this query in SQLPlus I don't receive any errors.

What is causing this warning?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 10 2010
Added on Mar 30 2010
5 comments
9,378 views