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!

ODBC SQL Server connection issue "String data, right truncation {01004}"

Ed HeatonJul 26 2017 — edited Jul 28 2017

Hi,

I have managed to create a partially functioning heterogeneous database link to SQL Server from Oracle. In TOAD, pulling back character data errors out with the following:

pastedImage_1.png

Pulling back numerical data is fine.

pastedImage_0.png

The Oracle database version is 12.1.0.2 running on Red Hat 6.7. I have used the following Microsoft driver:

ODBC Driver 13 for SQL Server.

Can anybody point me in the right direction on how to solve this frustrating issue?

My heterogeneous initSCOM.ora file which is located under $ORACLE_HOME/hs/admin looks like this:

# HS init parameters

HS_FDS_CONNECT_INFO = SCOM

HS_FDS_TRACE_LEVEL = Debug

HS_FDS_SHAREABLE_NAME = /usr/lib64/libodbc.so

# ODBC specific environment variables

set ODBCINI=/etc/odbc.ini

# Environment variables required for the non-Oracle system

#set <envvar>=<value>

Listener.ora file looks like this:

LISTENER =

(ADDRESS_LIST =

  (ADDRESS = (PROTOCOL = TCP)(HOST = \*\*\*\*\*\*\*\*\*)(PORT = 1521))

  (ADDRESS = (PROTOCOL = IPC)(KEY = \*\*\*\*\*\*\*\*\*))

)

SID_LIST_LISTENER =

(SID_LIST =

(SID\_DESC =

  (SID\_NAME = SCOM)

  (ORACLE\_HOME = /app/oracle/12102/db)

  (PROGRAM = dg4odbc)

 )

)

Tnsnames.ora entry looks like this:

SCOM =

(DESCRIPTION =

(ADDRESS\_LIST=

  (ADDRESS =

  (PROTOCOL = TCP)

  (HOST = localhost)

  (PORT = 1521)

 )

)

(CONNECT_DATA = (SID = SCOM))

(HS = OK)

)

Any assistance would be greatly appreciated,

Cheers

Ed

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 25 2017
Added on Jul 26 2017
7 comments
7,696 views