Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Connecting oracle server to SQL server

M.broMay 17 2022 — edited May 18 2022

Dear Team,
Oracle Database Version : 12.0.1
Sql Server Connectivity using ODBC
I am using oracle Database and trying to connect SQL Server using ODBC for the below steps but I am facing a different issues
ORA - 12638:Credential Retrieval failed.
ORA-28545 ERROR DIAGNOSED BY NET8 WHEN CONNECTING TO AN AGENT UNABLE TO RETRIEVE TEXT OF NETWORK/NCR MESSAGE 65553 ORA-02063 preceding 2lines from sqldb ORA-28545 ERROR DIAGNOSED BY NET8 WHEN CONNECTING

Below are the steps I followed to connect.
SEARCH ODBC Datasource 64 bit
image.png
FOR SERVER IP ADD IS (LOCAL MACHINE IP ADDRESS

S)
ask the user name password for the client
image.png
CLICK NEXT
image.png
CLICK NEXT
CLICK FINISH
image.png
CLICK --- CHECK DATA SOURCE
-------------------------------------------ODBC CONNECTION COMPLETED----------------------------------------------------
GO TO LOCATION ---> E:\app\rndbi\product\12.1.0\dbhome_1\hs\admin (IN SERVER)
TAKE BACK THE FILE(copy a file initdg4odbc.ora)
and edit the copy file and rename (add sql) like this
image.png
and right click and go to text pad in that copied file and add(#) in that line and change hs_fds_connetc_info name as (odbc database name)
image.png
image.png
and go to the loaction----> Go: E:\app\rndbi\product\12.1.0\dbhome_1\NETWORK\ADMIN
copy and paste the 2 file(ie is backup) like this
image.png
and edit listner.ora file
edit like this (add the code in that file (use the document for that particular code))
and check the location name and sid_name =sql
image.png
and edit tnsnames.ora file
edit like this (add the code in that file (use the document for that particular code))
and check the location name and sid=sql and check the db name (HOST=DB NAME)
image.png
GO TO CMD PROMPT
TYPE : LSNRCTL
START AND STOP THE LISTNER
GO TO CMD PROMPT
tnsping sqlconnection
tnsping sql_connection

image.png
check the marked name as tnsping as (tnsnames.ora)
and create a dblink in (toad)
user name as (sql server db name and paswword ask client) ('sql_connection' is in tnsnames.ora name file) create in live
CREATE PUBLIC DATABASE LINK sqldb CONNECT TO
"username" IDENTIFIED BY "password" using 'sql_connection'

-after that restart db service and listerner
get the table name in sql servers...without (dbo) use select

image.png
after creation check in select statement
Select *from table_name@sqldb

How to use where condition in db link:

select *from table_name@sqldb where "column_name"=' ';

Thanks & regards,
M.bro

Comments

User_C7DAK

Same issue - following

1 - 1

Post Details

Added on May 17 2022
0 comments
253 views