Page 1 of 1

Job Parameter removing quotes

Posted: Sat Jun 11, 2011 7:11 am
by myukassign
Hi...

I have a simple job like the following.

ODBC Stage ---------> Transformer ---------> Dataset.

In odbc, I am using a sql with an "IN" statement where in I want to give comma separted values. This comma separated values I want to give as a job parameter.

select X,Y,Z from TABA where state in ('A','B','C')

Even though I pass 'A','B','C' in the job parameter, datastage automatically remove that and the SQL is running with 'A,B,C'. Why it is automatically removing that? How to prevent or any alternative method to pass my desired value there.

Please request to help me here.

Posted: Sat Jun 11, 2011 7:35 am
by chulett
So it is removing quotes rather than colons. And that is a well documented "feature" of DataStage, it does that by default. If you had searched here, you would find the fix is to escape them.

Posted: Sat Jun 11, 2011 10:57 am
by myukassign
Yes, I searched and got my solution. Thanks Chullet.

For the interest of anyone who search for this the solution is here.

viewtopic.php?t=128561&highlight=