Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 not able to create a link server to Oracle 10G

Author  Topic 

titolulu
Starting Member

1 Post

Posted - 2007-09-19 : 16:41:50

Hi all,
I'm not able to create a link server to access an Oracle DB from SQL server. My environment:

- Windos XP
- SQL 2005 Dev SP2
- Oracle 10g & Client & Oracle Provider for OLD DB 10.2...

- MDAC 2.8

I linked Oracle from within SQL Management studio.
I'm able to Ping the server using TNSPING oracleservername and I'm able to connect to sql server using oracel tools
I test the connection to Oracle via OraOLEDB.Oracle.1 using a UDL file and the connection is successful.
Also I'm able to connect to the oracle server using the SSSI 2005 DTSwizard using the Oracle Provider for OLE DB
I'm NOT Able to connect using the linked server:

sp_addlinkedserver 'LS_ora10g', 'Oracle','OraOLEDB.Oracle','ORA10G_NAME.COM'
go
sp_addlinkedsrvlogin 'LS_ora10g','False', NULL, 'user', 'password'

MyTNSNAME.org is like:
ORA10G_NAME.COM =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = ORA10G_NAME.COM)(PORT = 1521))
)
(CONNECT_DATA =
(SID = oracleservername)
(SERVER = DEDICATED)
)

When I try test the connection o GOT

"The test connection to the linked server failed."

Cannot create an instance of OLE DB provider "OraOLEDB.Oracle" for linked server "LS_ora10g". (Microsoft SQL Server, Error: 7302)

Yes I check the AllowInProcess set to true, but still doesn't work.

My Registry on MSDTC is like this:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSDTC\MTxOCI

OracleOciLib = oci.dll
OracleSqlLib = SQLLib80.dll
OracleXaLib = xa80.dll

May be this values shoudl point to the new dll's fro ORACLE10G


Any ideas what is wrong ??

Is my sqlquery missing something???



titoDBA

PeterNeo
Constraint Violating Yak Guru

357 Posts

Posted - 2007-09-20 : 01:59:52
Hi,

check the Article on how to add Oracle as Linked Server, it may help u
http://www.databasejournal.com/features/mssql/article.php/10894_3290801_1

Go to Top of Page
   

- Advertisement -