How to run oracle sql file from PHP using Adodb
1 Answer
If it's just a normal sql statement you could just read the file with file_get_contents and execute it.
$rs = $DB->Execute(file_get_contents('query.sql'));
3 Comments
Mikhail T.
Is there any way to pass the filename to the Oracle client library? So that the library does the reading of it, instead of the caller doing it?
winkbrace
That wouldn't make sense, since the library needs to work everywhere, not only for your one script. :)
Mikhail T.
I don't think, you understood my question. What I'm looking for is some equivalent to
$DB->ExecuteFile('query.sql')). Is there such a thing?