I've been playing around with PDO and oracle drivers.

PDO seems to be the right way to go, but the oracle implementation it is still very immature and prepare statements don't seem to work.

I am using oracle instant client 10.2

The problems I found are when doing prepared statements. If I use bindParam or bindValue, when executing the statement, with errorInfio() I get this:
OCIStmtExecute: ORA-24343: user defined callback error

and PHP throws this warning:
Debug Warning: Session_PDO.class.php line 95 - PDOStatement::execute() [<a href='function.execute'>function.execute</a>]: param is NULL in oci_bind_input_cb; this should not happen

Now, If I instead execute the statement and do the binding at the same time, I don't get any errors, but the fields in the table are inserted empty. I am doing this:
                ':value' => $val,
                ':random' => md5(uniqid(rand(),1)),
                ':session_id' => $key
                ) );

I also tried binding with the value names like :random and with numbers and getting the same results.

Any ideas if I am doing something wrong or if the oracle implementation is still so immature. If this is so, what are the plans to get this implementation along the status of mysql (which I tried and it works fine).

I appreciate any feedback,
Pablo Godel

PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to