Hi All,
PHP 5.0.2
Oracle 10g
RedHat Linux
I'm quite new to PHP so I hope you experts can help me out.
I'm calling an Oracle SP which is returning a ref cursor.
I'm getting the following output:
array(1) { [0]=> resource(6) of type (oci8 statement) }
when I run the code below. I'm expecting 14 rows.
I've literally tried every combination I can think of: using ora_ calls, changing it to an Oracle FUNCTION etc.. but all resulting in the same message (as above)
I'd be eternally grateful if you guys could help me out.
Rgds,
Joe.
$c1 = oci_new_connect("bobs", "your", "uncle");
$curs = OCI_New_Cursor($c1);
$queryString = "BEGIN myspname ('bla', 'bla', 'bla', :result); END;";
$stmt = oci_parse( $c1, $queryString );
OCI_Bind_By_Name($stmt, "result", &$curs, -1, OCI_B_CURSOR);
$res = oci_execute($stmt, OCI_DEFAULT) ;
$res = oci_execute($curs) ;
$data = OCI_Fetch_row($curs) ;
var_dump($data);
oci_free_statement($stmt);
oci_free_statement($curs);
oci_close($c1);