Pro*C: Connecting to Oracle???
Date: 24 Oct 1994 13:58:55 -0700
Message-ID: <38h76f$4vq_at_crl7.crl.com>
I am experiencing a problem when re-connecting to Oracle using Pro*C.
Oracle version: ORACLE7.
Machine: RS6000/AIX
My program is a daemon. But before it becomes a daemon, I connect to Oracle using the following type of Pro*C call:
varchar Username[20];
.
.
.
strcpy(Username.arr, "henry/smith"); /* username and password are */ Username.len = strlen(Username.arr); /* fictitious of course */
EXEC SQL CONNECT :Username;
Everything is ok. When I do a ps -ef, I notice that the my Oracle process is running with the LOCAL=YES parm. This is ok since the database instance is on the same processor that I am.
After the program becomes a daemon, I disconnect from ORACLE using:
EXEC SQL COMMIT WORK RELEASE; Still no problem.
However, if I attempt to reconnect to Oracle in the same way, I get an ORA12203 error message which is an SQL*NET error.
If, however, I reconnect with the Username set as "henry/smith_at_oracledb" it connects ok BUT, now it is LOCAL=NO. It has connected to the local db via SQL*NET.
How do I reconnect as a daemon and make it a local connection?
Thanks,
Henry Smith
-- Henry Smith (hbs_at_crl.com)Received on Mon Oct 24 1994 - 21:58:55 CET