Cant connect to OraOLEDB

General discussion forum about all databases other than SqlBase.
kvzombie

Cant connect to OraOLEDB

Post by kvzombie » 14 Jan 2014, 15:54

im working on a app, that uses 2 kinds of data base, SQLSERVER and ORACLE.

It works fine with SQLSERVER connection, but when i try to connect to OraOLEDB. it throws this error:

ORA-12154: TNS:no se ha podido resolver el identificador de conexión especificado.

Im using SqlCreateSession(hSqlSession, sSessionOledb). this gives me the error.

the values of the parameters are:

hSqlSession = 0h
sSessionOledb = "Provider=OraOLEDB.Oracle;Data Source=10.200.10.213/monarch;Catalog=WINPER;Persist Security Info=False;"

can someone help me?

User avatar
markus.essmayr
Site Admin
Site Admin
Austria
Posts: 892
Joined: 06 Mar 2017, 06:07
Location: Austria

Re: Cant connect to OraOLEDB

Post by markus.essmayr » 15 Jan 2014, 07:16

Hello,

I'm not completely sure, if your connection string need to have tnsnames.ora set up correctly.
Maybe you can use this syntax:

Code: Select all

Provider=OraOLEDB.Oracle;
Data Source=(DESCRIPTION=(CID=GTU_APP)(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=myHost)(PORT=myPort)))(CONNECT_DATA=(SID=MyOracleSID)(SERVER=DEDICATED)));
User Id=myUsername;Password=myPassword;
Have a look at: http://www.connectionstrings.com/oracle ... -oraoledb/

Max
Markus Eßmayr
teamdeveloper@t-mx.com

Return to “General Discussion”

Who is online

Users browsing this forum: [Ccbot] and 0 guests