IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Sorting 400 byte record in packed format


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
ankit9jain

New User


Joined: 20 Jan 2009
Posts: 17
Location: India

PostPosted: Wed Feb 18, 2009 3:48 pm
Reply with quote

I have a requirement mentioned below:
KEEP Record if one of the following condition is met:
- REC DATE > YESTERDAY'S DATE
- REC DATE = YESTERDAY'S DATE AND
REC has values equal to zero in column 11-16
- REC DATE = YESTERDAY'S DATE AND
REC has 'N' in column 388 and 'C' in col 390

Input file has date in col 1-5 in Packed format
Input and output both are 400 byte record in packed format. i wrote the below sort card for it but it is not giving the desired result.
Code:

OPTION COPY                   
INCLUDE COND=(1,5,PD,GT,TARGET,
        OR,1,5,PD,EQ,TARGET,   
        AND,11,6,PD,EQ,ZEROES,
        OR,1,5,PD,EQ,TARGET,   
        AND,388,1,CH,NE,C'N', 
        AND,390,1,CH,NE,C'C') 

i am using TARGET as the label for the yesterday's date using different code .
Could anyone let me know whether the code is correct according to the req. i have mentioned
Back to top
View user's profile Send private message
aishwarya_20

New User


Joined: 19 Nov 2008
Posts: 57
Location: pune

PostPosted: Wed Feb 18, 2009 3:54 pm
Reply with quote

Hi,

Please try with this.
OPTION COPY
INCLUDE COND=((1,5,PD,GT,TARGET),
OR,(1,5,PD,EQ,TARGET,
AND,11,6,PD,EQ,ZEROES),
OR,(1,5,PD,EQ,TARGET,
AND,388,1,CH,NE,C'N',
AND,390,1,CH,NE,C'C'))
Back to top
View user's profile Send private message
ankit9jain

New User


Joined: 20 Jan 2009
Posts: 17
Location: India

PostPosted: Wed Feb 18, 2009 4:18 pm
Reply with quote

thanks...
but it is still not working..
it is saying syntax error
PD,EQ,ZEROS)
*
Back to top
View user's profile Send private message
aishwarya_20

New User


Joined: 19 Nov 2008
Posts: 57
Location: pune

PostPosted: Wed Feb 18, 2009 4:42 pm
Reply with quote

Then there would syntax problem. Check the ZEROS spelling if it is correct syntax
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Wed Feb 18, 2009 10:07 pm
Reply with quote

ankit9jain,

Use the following control cards. You don't have to spell out zeros.
Code:

  OPTION COPY                   
  INCLUDE COND=((1,5,PD,GE,TARGET,AND,11,6,PD,EQ,0),OR,
    (1,5,PD,EQ,TARGET,AND,388,1,CH,NE,C'N',AND,390,1,CH,NE,C'C')) 
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Populate last day of the Month in MMD... SYNCSORT 2
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts Modifying Date Format Using DFSORT DFSORT/ICETOOL 9
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
Search our Forums:

Back to Top