Page 1 of 1

ODBC Invalid Precision value

Posted: Thu Jul 05, 2018 2:18 pm
by dskid
Hi,
We are moving our jobs from 8.5 to 11.7 and our jobs extract data from SQL Server to Oracle 12c. These jobs are RCP enabled and we use ODBC stage for loading data into target.

This jobs extracts data from intermediate Dataset to Oracle. We don't have any problem running these jobs in 8.5, but in 11.7 we get the below error whenever there is a length miss-match between source and target fields. In source for one of field lengths is VARCHAR 5000 and target length is VARCHAR 4000.

So we changed the length in target to 5000 (after enabling MAX_STRING_SIZE= extended in Oracle), I am still getting the same error. Any suggestions please? I was able to load other tables where the lengths are matching.

ODBC_Connector_13,0: ODBC function "SQLExecute" reported: SQLSTATE = HY104: Native Error Code = 0: Msg = [IBM(DataDirect OEM)][ODBC Oracle Wire Protocol driver]Invalid precision value. Error in parameter 14. (CC_OdbcDBStatement::executeInsert, file CC_OdbcDBStatement.cpp, line 832)

Posted: Mon Jul 09, 2018 12:36 am
by ray.wurlod
Are the Oracle data types specified in BYTES or in CHARACTERS?

Posted: Mon Jul 09, 2018 8:08 am
by dskid
Hi Ray,
In Target Oracle, it is defined as VARCHAR2(5000 BYTE).

Posted: Mon Jul 09, 2018 10:17 am
by chulett
So... which 12c version of Oracle? VARCHAR2 have been limited to 4000 bytes since forever until recently and you need to have set MAX_STRING_SIZE = EXTENDED for it to exceed that - up to 32767 bytes in that case. I wonder if that option is fully supported by ODBC / RCP... may need to be a support question.

Posted: Mon Jul 09, 2018 2:12 pm
by dskid
Yes, this has been sent to support as well. Thought will check in the forum if some one has already went thru this issue before. Anyway i will update the thread as soon as i hear from IBM