Hritam
New User
Joined: 27 Jun 2005 Posts: 36 Location: India
|
|
|
|
Hi,
I have the following requirement. I know we can do this by coding three difft steps but I would like to know if it can be done in a single step:
Step 1: Extract only those records having current address effective date greater than 15th November 2008 and Field ABC not equal to X or Y. This will be file 1.
Step 2: Extract only those records having current address effective date greater than 1st February 2009 and Field ABC equal to X and Y. This will be file 2.
Step 3: Concatenate file 1 and file 2 and copy it back to File3.
File length = 250
Field description:
===============
Effective date
Length PIC X(10)/MM-DD-YYYY
Position = 20
ABC
Length PIC X(1) /Char
Position = 32
Thanks,
Hritam |
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
I don't understand your description. Are file1 and file2 separate input files or separate output files or ? Are you trying to create file1 and file2 as separate output files and then concatenate them as output file3? Why? Why not just create them as output file3 in the first place?
Please show an example of the records in the input file, or in each input file, and the expected output file or files. Show relevant values in the records for the effective date field and ABC field. Give the RECFM and LRECL of the files.
As for the position, length and format of the fields:
I think you're saying that the effective date field starts in position 20, has a length of 10 and is character format (C'MM-DD-YYYY') - right?
I think you're saying that the ABC fields starts in position 32, has a length of 1 and is character format - right? |
|