Page 1 of 1

Error while passing SQL as a parameter

Posted: Mon Apr 23, 2012 12:32 pm
by sreelalpp
Hello,

I am facing an error with a Datastage 8.5 Parallel Job. I have a job that reads from a mainframe DB2 Table (Using DB2 Connector) and writing into a Teradata Table( Using TD Connector).

The job is running fine when I keep the SQL Statement (that reads from the source table) in the DB2 Connector Stage.

But when i make the same SQL as a parameter and assign the parameter name in the DB2 Connector, the job is aborting. It looks like the DB2 connector is not able to import the metadata of the source table.

In my job RCP is enabled and no column names are mentioned.

Please share your thoughts on the situation. Is there any limit in the number of charactors allowed in a parameter value ? my SQL has 400 Charactors in it.

thanks for your help

Sree

Posted: Mon Apr 23, 2012 12:53 pm
by chulett
Why is it aborting when you use a parameter? Does the sql include quotes and does it look like the quotes are being stripped out? If so, there's an APT environment variable that may help...

ps. While I'm sure there's a limit, 400 wouldn't be anywhere near it, so the size should be a non-issue.

Posted: Mon Apr 23, 2012 1:57 pm
by sreelalpp
Thanks chulett,

I guess the quotes are the problem. I have a field hard coded in the SQL.

May i know the APT variable i should use ?

thanks
Sree

Posted: Mon Apr 23, 2012 2:45 pm
by chulett
I don't have access to my notes right now, let me see... one sec... here, this should help: viewtopic.php?t=145303