Page 1 of 1

Lookup Operator Error

Posted: Thu Jul 12, 2012 8:23 am
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?

Posted: Thu Jul 12, 2012 10:11 am
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,

Posted: Thu Jul 12, 2012 11:53 am
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?

Posted: Thu Jul 12, 2012 1:30 pm
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,

Posted: Fri Jul 13, 2012 1:45 am
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.