Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: INSERT ... VALUES( :placeholder1, ...)

Re: INSERT ... VALUES( :placeholder1, ...)

From: Opi <opi_at_volny.cz>
Date: Tue, 15 Jan 2002 00:12:38 +0100
Message-ID: <a20tvf$re8$1@ns.felk.cvut.cz>


Dont tell me anything - I know, I know... I should take a rest for a while :)

"Opi" <opi_at_volny.cz> píše v diskusním příspěvku news:...
| Hi, I have written a recursive script in PHP that scans directory tree and
| saves it to a single table. That was for mysql, and now when I'm tampering
| with Oracle, I want to see it in action, so I have parsed this statement:
|
| $sql =
| "DECLARE dohajzlu NUMBER(5);"
| ."BEGIN SELECT godir_i.NEXTVAL INTO :dohajzlu FROM DUAL;"
| ."INSERT INTO godir VALUES(:dohajzlu, :pod, :xpath);".
| "END;";
|
| // then...
| $b_curid = 0;
| OCIBindByName($stmt,":dohajzlu",&$b_curid,32);
| OCIBindByName($stmt,":pod",&$b_pod,32);
| OCIBindByName($stmt,":xpath",&$b_xpath,32);
|
| It works fine - until the $xpath contains something bad. It works with
| "C:/mp3/Republica", "C:/mp3/Mike Oldfield", ... , but doesn't with
| "C:/mp3/Mike Oldfield/1974 - Hergest Ridge", and it prints out this error:
| "ORA-01460: no-sence or non-implemented conversion demanded"
(Translated
| from Czech, don't know the exact phrase.)
|
| Please tell me what's wrong, and also please, tell me how to escape
various
| chars, like \, &, ' etc.
|
| Thanks, Opi
|
|
Received on Mon Jan 14 2002 - 17:12:38 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US