Technical one with Oracle and ODBC...

jtallon

Golden Member
May 13, 2001
1,166
0
0
It's a longshot, but there's an awful lot of geeks in this group :)

I've got a database running Oracle 8.1.7, and the latest Oracle client CD installed. When I connect via ODBC to the database, it works, but some of my function calls don't work because I don't have envorinment variables set in Oracle that I need.

Does anybody know how to set enviornment variables or call a stored procedure upon connection through ODBC ? Wondering if I need to dump something in the sqlnet.ora file or something like that...

Thanks !
 

ZaneNBK

Golden Member
Sep 14, 2000
1,674
0
76
Using ADO an ODBC connected to Oracle you can execute a stored procedure like so:

oConnection.Execute("{call sp_ProcName("arg1", "arg2");}")

I don't recall wether that semicolon is necessary or not.

As for using environment variables via ODBC I can't help you there. I never use environment varaibles. If everyone needs access to these variables I would make them part of a settings table. If they're user specific environment variables I would pass them as parameters to your procedures or have a user settings table.