View previous topic :: View next topic
Author
Message
ranga_subham New User Joined: 01 Jul 2005Posts: 51
Hi,
I have some input data as followed:
IN01AAAAAAAA6868AOBOCO
IN02BBBAAAAA1111AOBOCO
IN01ABABABAB6868AOBOCO
IN03BABABABA4678AOBOCO
IN02BABABABA6868AOBOCO
IN02BABABBBA6868AOBOCO
IN03AAAABBBA9878AOBOCO
IN01ABABABAB2222AOBOCO
IN01BBBBBBBB1212AOBOCO
Now, I want omit all those records that have 02 in 3rd & 4th column and 6868 in 13th to 16th column. Also, I want to omit all the records that have 01 in 3rd and 4th column. Please let me know how the SORT card will look like.
Thanks in advance.
Back to top
rssomm New User Joined: 05 Jun 2005Posts: 41 Location: Hyderabad
Please try following code.
Omit Cond=(2,2,ch,eq,c'02',and,13,4,ch,eq,c'6868',or,2,2,ch,eq,c'01')
Madhu..
Back to top
Frank Yaeger DFSORT Developer Joined: 15 Feb 2005Posts: 7129 Location: San Jose, CA
If your requirements can be written this way:
"I want to omit all of the records that have 02 in 3rd & 4th column and 6868 in 13th to 16th column, or that have 01 in 3rd and 4th column."
then you can write the corresponding DFSORT OMIT statement like this:
Code:
OMIT FORMAT=CH,
COND=((3,2,EQ,C'02',AND,13,4,EQ,C'6868'),OR,3,2,EQ,C'01')
The output records would be:
Code:
IN02BBBAAAAA1111AOBOCO
IN03BABABABA4678AOBOCO
IN03AAAABBBA9878AOBOCO
Back to top
ranga_subham New User Joined: 01 Jul 2005Posts: 51
Thank you Frank.
Back to top
Please enable JavaScript!