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!

Insert into MSSQL from Oracle

Joe_990933May 2 2013 — edited Jul 5 2013
Hello together,

I'm a little bit frustrated. The follwoing is my problem:

I want to insert some values from an Oracle 10gR2 database into a MSSQL database (SQL Server 2008 R2).
Therefor I'm using DG4ODBC 11.2.0.3. The connection is working absolutly fine.

I want to insert five values from five columns from oracle.table-a into a msssql table-b.
But I'm hitting the error:

Invalid character value for cast specification.

Two columns from the oracle table are chars size 12 and 40, and three are number size 5.1, 5.1 and 4.
The MSSQL column definitions are varchar40, varchar50, 2x float8 and int.

The column assignments are:

Oralce -> MSSQL
a. char 12 -> varchar40
b. char 40 -> varchar50
c. number 5.1 -> float8
d. number 5.1 -> float8
e. number 4 -> int4

The insert works greate for a,b and e but nor for c and d.

I tried so many solutions (cast, to_binary_float, nls_character_format, nls_theritpory etc..) but nothing helps.

I always hitting this error.

Can anyone help me with this problem?

cheers

Joe
This post has been answered by Joe_990933 on Jul 5 2013
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 2 2013
Added on May 2 2013
6 comments
974 views