i used example in demo directory to connect Datatbase.
I used "ansidyn1" example. But i can connect to my DB.
I have just modified oracle_connect in sample code(in ansidyn1.pc),follow it:
EXEC SQL BEGIN DECLARE SECTION;
char DB_NAME = "servertest";
char db_string= "vitcendb";
EXEC SQL END DECLARE SECTION;
EXEC SQL CONNECT :username IDENTIFIED BY :password
AT :DB_NAME USING :db_string;
and in my tnsname.ora
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.176.191)(PORT = 1521))
(SERVICE_NAME = vitcendb)
i compiled in in VC6++(using ansidyn.dsp) but cant connect to DB
please tell me what's wrong?
username and password is correct!
[Updated on: Sun, 30 November 2008 20:32]
Report message to a moderator