Hi,
I am getting the following error in datastage while trying to insert to a table using ODBC connector.
[IIS-CONN-ODBC-000004] ODBC function "SQLExecute" reported: SQLSTATE = 22001: Native Error Code = -302: Msg = [IBM][CLI Driver][DB2/LINUXX8664] SQL0302N The value of a host variable in the EXECUTE or OPEN statement is too large for its corresponding use. SQLSTATE=22001
Has anyone come across this in DS and can you pls help. Thanks.
Error while INSERT in ODBC stage
Moderators: chulett, rschirm, roy
Re: Error while INSERT in ODBC stage
Are you using ODBC Enterprise stage or ODBC Connector stage, Connector stage does not Open command option.
arul wrote:Hi,
I am getting the following error in datastage while trying to insert to a table using ODBC connector.
[IIS-CONN-ODBC-000004] ODBC function "SQLExecute" reported: SQLSTATE = 22001: Native Error Code = -302: Msg = [IBM][CLI Driver][DB2/LINUXX8664] SQL0302N The value of a host variable in the EXECUTE or OPEN statement is too large for its corresponding use. SQLSTATE=22001
Has anyone come across this in DS and can you pls help. Thanks.
Re: Error while INSERT in ODBC stage
We are using ODBC Connector stage.
The command is a INSERT command (generated by the ODBC connector stage based on the columns)
The command is a INSERT command (generated by the ODBC connector stage based on the columns)
tayebir wrote:Are you using ODBC Enterprise stage or ODBC Connector stage, Connector stage does not Open command option.
arul wrote:Hi,
I am getting the following error in datastage while trying to insert to a table using ODBC connector.
[IIS-CONN-ODBC-000004] ODBC function "SQLExecute" reported: SQLSTATE = 22001: Native Error Code = -302: Msg = [IBM][CLI Driver][DB2/LINUXX8664] SQL0302N The value of a host variable in the EXECUTE or OPEN statement is too large for its corresponding use. SQLSTATE=22001
Has anyone come across this in DS and can you pls help. Thanks.
Arul
Yes DSGUru. We tried that. also, when we tried dividing the data into different ranges, it is working, but if we pass all the data, it is not working.
DSguru2B wrote:Did you try searching for error code "SQL0302N" in google. Try that. It seems like the input value is too large for a given column that you are trying to insert.
Arul
Yes, I mean running half the rows in one run and another in the second run.
We tried using ODBC EE stage, but it gives the same error... I will try with DB2 EE.
We tried using ODBC EE stage, but it gives the same error... I will try with DB2 EE.
DSguru2B wrote:What do you mean by different ranges? Do you mean half the rows in the first run and the rest in the second run? What happens if you use DB2 enterprise stage, do you still have the same error?
Arul