Incorrect No. of columns error while using Join

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
pxraja
Participant
Posts: 142
Joined: Fri Mar 14, 2008 10:22 am

Incorrect No. of columns error while using Join

Post by pxraja »

Hi all,

I am joining two tables like tbl1, tbl2 having 10 fields and 4 fields each having Inlinktbl1.Field1 and Inlinktbl2.Field2 as key columns

-----------------ODBC
--------------------|
--------------------|
ODBC------->TRF------->ODBC

I am taking 9 fields from tbl1 and 3 fields from tbl2
and using the key fields in constraint as inner join.

the job is aborted showing the error like..

DSD.BCIOpenRef call to SQLNumResultCols failed.SQL statement has incorrect number of result columns.

I could not get anything from this...

Any suggestions are welcomed

Thanks in advance
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Ah, the perils of user-defined sql. You need to select the same number of columns as are defined in the stage, in the exact same order.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply