?php / * Calling PL / SQL stored procedures which contain clobs as input * parameters (PHP 4 = 4.0.6). * Example PL / SQL stored procedure signature is: * * PROCEDURE save_data * Argument Name Type In / Out Default? * ----------------------------- - ---------------------- - ----- - ------- - * KEY NUMBER(38) IN * DATA CLOB IN * * / $conn = OCILogon($user, $password); $stmt = OCIParse($conn, "begin save_data(:key, :data); end ;"); $clob = OCINewDescriptor($conn, OCI_D_LOB); OCIBindByName($stmt, ':key', $key); OCIBindByName($stmt, ':data', $clob, -1, OCI_B_CLOB); $clob - WriteTemporary($data); OCIExecute($stmt, OCI_DEFAULT); OCICommit($conn); $clob - close(); $clob - free(); OCIFreeStatement($stmt);?
?php / * Appel d'une procédure PL / SQL stockée qui prend un clobs * en entrée (PHP 4 = 4.0.6). * Exemple de signateure de procédure stockée PL / SQL: * * PROCEDURE save_data * Nom de l'argument Type In / Out Default? * ----------------------------- - ---------------------- - ----- - ------- - * KEY NUMBER(38) IN * DATA CLOB IN * * / $conn = OCILogon($user, $password); $stmt = OCIParse($conn, "begin save_data(:key, :data); end ;"); $clob = OCINewDescriptor($conn, OCI_D_LOB); OCIBindByName($stmt, ':key', $key); OCIBindByName($stmt, ':data', $clob, -1, OCI_B_CLOB); $clob - WriteTemporary($data); OCIExecute($stmt, OCI_DEFAULT); OCICommit($conn); $clob - close(); $clob - free(); OCIFreeStatement($stmt);?