Page 1 of 1

[IBM][CLI Driver] CLI0112E Error in assignment. SQLSTATE=22

Posted: Mon Feb 15, 2010 12:14 am
by sb2212
I am building a simple job wherein I am using a DB2/UDB stage and linking it to a sequential file.
I am specifying a user defined query like

Code: Select all

"SELECT COL1,COL2 FROM TABLE WHERE IN COL1 IN (111,112,113)"
When I execute the query i get the following error and the job aborts.
[IBM][CLI Driver] CLI0112E Error in assignment. SQLSTATE=22005

What has gone wrong here?

Re: [IBM][CLI Driver] CLI0112E Error in assignment. SQLSTAT

Posted: Mon Feb 15, 2010 12:17 am
by gssr
sb2212 wrote:

Code: Select all

"SELECT COL1,COL2 FROM TABLE WHERE IN COL1 IN (111,112,113)"

What has gone wrong here?
Try this,

Code: Select all

"SELECT COL1,COL2 FROM TABLE WHERE COL1 IN (111,112,113)"

Posted: Mon Feb 15, 2010 12:22 am
by sb2212
sorry that was typo error from me.

it is

Code: Select all

select col1,col2 from table where col1 in (111,112,113)

Posted: Mon Feb 15, 2010 12:33 am
by gssr
Can you able to execute the query sucessfully in Command line in DB2?

I think the problem is from DB end!!!

Posted: Mon Feb 15, 2010 12:39 am
by sb2212
Yes in the command line I am able to get the result.

Posted: Mon Feb 15, 2010 12:49 am
by gssr
The Problem is due to Datatype mismatch,

Check out this,

viewtopic.php?t=107217&highlight=SQLSTATE%3D22005

Posted: Mon Feb 15, 2010 12:53 am
by sb2212
ya the problem is solved.

Posted: Mon Feb 15, 2010 1:06 am
by ray.wurlod
HOW is the problem solved?

Was it that the data type of COL1 was not some kind of integer?

In any case please mark this thread as Resolved using the green button at the top.