
IMPOSSIBLE TASK: Connect to Oracle 8 database using Active Server Pages
I promised a followup if I found an answer to my own question. I did, and
here it is, straight from the mouths of Oracle:
"System error 5" is an undocumented (or poorly documented) error message
that means "some Oracle component didn't have privileges for some object."
Whoopie...
The suggestion was to check the privs on the ODBC DLL's. I did that, all
looked OK, but to be sure I temporarily gave Everyone group Full Control.
Still wouldn't work.
I then went hunting for the file(s) where the database server and/or IIS
didn't have sufficient privs. It turned out to be one or more files in my
Oracle Home directory. This just blows me away, but it is true.
*Something* is invoked by the IIS-ODBC-Oracle connection that *is not*
invoked by the regular NetworkClient-ODBC-Oracle connection. I have yet to
narrow the problem to the actual file(s) in question. Neither has Oracle
for that matter, they asked that I contact them when I find them.
Thanks to all who wrote about the Listener problem, I had already found that
one but it's good to get a refresher.
Mark
Quote:
>I am finding it utterly impossible to connect to an Oracle 8 database using
>Active Server Pages. I've read every piece of literature I can find on
this
>subject, am familiar with all the known bugs, have followed all
suggestions,
>input supposedly-working example code verbatim, an it still will not work.
>Would appreciate any info, email preferred, will post followup with fixes
if
>there is indeed a fix.
>Mark Alsip
>Contractor to KY Dept of Insurance
>-----*** My environment:
> Windows NT V4/SP3.
> Oracle 8.0.5 server & ODBC driver (with 8.0.51b patch applied to ODBC).
> Also have Microsoft MDAC V2 with their ODBC driver for Oracle.
> IIS V3 with Active Server Pages.
> All above run on the same system.
> 32-bit DSN's defined for both Oracle and Microsoft ODBC connections to
>target database.
>-----*** Tests:
> Oracle ODBC test against both DSN's works perfectly.
> Database can be accessed flawlessly via Visual Basic and either ODBC
>driver installed on a client
> machine across the network.
> Database can be accessed locally and across the network using SQL
>Worksheet or SQL Plus
>-----*** My ASP code snippet using Microsoft ODBC driver for Oracle:
> Set db = Server.CreateObject("ADODB.Connection")
> db.open "DSN=KYDOI_MS;UID=DOI;PWD=blahblah;"
>This code fails with:
> Microsoft OLE DB Provider for ODBC Drivers error '80004005'
> Microsoft][ODBC Driver Manager] Driver's SQLAllocHandle on SQL_HANDLE_ENV
>failed
>-----*** My ASP code snippet using Oracle driver:
> Set db = Server.CreateObject("ADODB.Connection")
> db.open "DSN=KYDOI;UID=DOI;PWD=blahblah;"
>This code fails with:
> Microsoft OLE DB Provider for ODBC Drivers error '80004005'
> Specified driver could not be loaded due to system error 5 (Oracle ODBC
>Driver).