SQL error Messages

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
nilotpalr
Participant
Posts: 29
Joined: Tue Dec 10, 2002 2:54 am

SQL error Messages

Post by nilotpalr »

Hi All,
While executing jobs with ODBC stages often I get the following 2 errors which I am unable to comprehend:
1)Invalid Cursor state.
2) SQL statement has incorrect number of result columns( this error occurs when I use a ODBC stage for Lookup)
Please help me in understanding why these errors occur and how to solve them.

Could someone also give some clue on how to use stored procedures through Datastage

Thanks in advance..
Regards,
Nilotpal
WoMaWil
Participant
Posts: 482
Joined: Thu Mar 13, 2003 7:17 am
Location: Amsterdam

Post by WoMaWil »

Hi All,
While executing jobs with ODBC stages often I get the following 2 errors which I am unable to comprehend:
1)Invalid Cursor state.
2) SQL statement has incorrect number of result columns( this error occurs when I use a ODBC stage for Lookup)
Please help me in understanding why these errors occur and how to solve them.

Could someone also give some clue on how to use stored procedures through Datastage

Thanks in advance..
Regards,
Nilotpal

Hi Nilotpal,

you have to be careful with your statements. When doing lookup you have to ensure, that you get back only one row.
If the lookup fits to more then one row you get this error-message. You can filter your lookup for example with a group by statement for to get back only one row.

Wolfgang
Post Reply