Senthilkumar k Warnings : 1 New User
Joined: 07 May 2009 Posts: 51 Location: Chennai
|
|
|
|
I have a requirement like below, can any one help me,
I have a VSAM(KSDS) file like below, LRECL = 550
SE1879909277768296200907241150P086690.... .
SE1879909277768296200907241150P086691.... .
SE1879909277768296200907241150P086692.... Y
SE1979909277956094311502009072319911366.. .
SE1979909277956094311502009072319915878..Y
1. If byte from 1 to 4 is equal to SE18 and bytes from 19 to 26 is greater than (current date - 7).
(OR)
2. If byte from 1 to 4 is equal to SE19 and byte from 24 to 31 is greater
than (current date - 7).
(OR)
3. If byte 42 is not equal to Y.
If above any one of the condition is satisfied for a record then needs to write that record into file1. |
|
Skolusu
Senior Member
Joined: 07 Dec 2007 Posts: 2205 Location: San Jose
|
|
|
|
senthilkumar,
Use the following DFSORT control cards
Code: |
//SYSIN DD *
SORT FIELDS=COPY
RECORD TYPE=F
INCLUDE COND=((01,4,CH,EQ,C'SE18',AND,19,8,CH,GT,DATE1-7),OR,
(01,4,CH,EQ,C'SE19',AND,24,8,CH,GT,DATE1-7),OR,
42,1,CH,EQ,C'Y')
/* |
|
|