Lookup Operator Error

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
nikhil_bhasin
Participant
Posts: 50
Joined: Tue Jan 19, 2010 4:14 am

Lookup Operator Error

Post by nikhil_bhasin »

Hi,

I am getting following error in my job:-

main_program: Syntax error: Error in "lookup" operator: Error in output redirection: Error in output parameters: Error in modify adapter: Error in binding: Could not find type: "subrec", line 330

I am doing a lookup in my job where the refernce data is coming from a cff file.

Any insights on this error?
jwiles
Premium Member
Premium Member
Posts: 1274
Joined: Sun Nov 14, 2004 8:50 pm
Contact:

Post by jwiles »

Is the reference data key column contained within an OCCURS clause, or perhaps is not a top-level column? If so, it may be part of a subrec definition within the orchestrate schema. I don't know if subrecs are supported for lookup keys (your official support provider can assist you there). If not, you may need to flatten the record prior to the lookup stage.

Regards,
- james wiles


All generalizations are false, including this one - Mark Twain.
nikhil_bhasin
Participant
Posts: 50
Joined: Tue Jan 19, 2010 4:14 am

Post by nikhil_bhasin »

There is no OCCURS clause for the key column. In fact, there are only 2 columns in the file. Also, i tried reading the file in a separate job and wrote it to a dataset, and used the dataset for lookup. But again it gave the same fatal error.
The key column is a char column. It might have some junk chars in it. Can that be a reason for this error?
jwiles
Premium Member
Premium Member
Posts: 1274
Joined: Sun Nov 14, 2004 8:50 pm
Contact:

Post by jwiles »

That's not likely the reason for the error. The keyword "subrec" is a data element within an orchestrate schema, and CFF uses subrecs for several of the elements found within COBOL File Descriptors.

You can get a look at the schemas by adding the OSH_PRINT_SCHEMAS environment variable to your job and setting it to 1.

Instead of writing the reference data to a dataset, try writing to a sequential file instead.

What about the main data stream...is it also from a CFF file?

Regards,
- james wiles


All generalizations are false, including this one - Mark Twain.
nikhil_bhasin
Participant
Posts: 50
Joined: Tue Jan 19, 2010 4:14 am

Post by nikhil_bhasin »

Found the reason, why it was aborting. Its the issue of level number of those columns which were being added in transformer. Their level number was blank and the columns that were being taken from cff file had it as 02. Added the level number and job worked.
Post Reply