Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

retrieve all records from dataset older than certain date

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
vicharapusrinu
Warnings : 1

New User


Joined: 04 Dec 2006
Posts: 63
Location: Hyderabad

PostPosted: Thu Sep 02, 2010 7:55 pm    Post subject: retrieve all records from dataset older than certain date
Reply with quote

I/P file details

RF –FB
LRECL—100


Date started at 19th position in MM/DD/YY format

Ex: 03/23/09 is at 19th position to 26th position

I would like to retrieve all records from data set which is older than 03/23/10

Ex:
02/20/09
08/22/08
03/20/10…… etc

Regards,
Srini.
Back to top
View user's profile Send private message

Skolusu

Senior Member


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

PostPosted: Thu Sep 02, 2010 9:30 pm    Post subject:
Reply with quote

Yvonne1980,

Use this DFSORT JCL

Code:

//STEP0100 EXEC PGM=SORT   
//SYSOUT   DD SYSOUT=*     
//SORTIN   DD DSN=Your input 100 byte FB file,DISP=SHR
//SORTOUT  DD SYSOUT=*                                 
//SYSIN    DD *                                         
  SORT FIELDS=COPY                                     
  INREC OVERLAY=(101:19,8,UFF,M11,LENGTH=6)             
  OUTFIL BUILD=(1,100),INCLUDE=(101,6,Y2W,LT,Y'100323')
//*
Back to top
View user's profile Send private message
vicharapusrinu
Warnings : 1

New User


Joined: 04 Dec 2006
Posts: 63
Location: Hyderabad

PostPosted: Fri Sep 03, 2010 12:21 pm    Post subject:
Reply with quote

Skolusu,

Thanks for providing solution,

Could you please let me know what would be changes in sort cart if my input data set is VB?


Regards,
Srini.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10210
Location: italy

PostPosted: Fri Sep 03, 2010 1:04 pm    Post subject: Reply to: retrieve all records from dataset older than certa
Reply with quote

that all Your fields positions/offset will have to be shifted right 4 bytes to account for the RDW

for a F[B] record the first <userdata> byte will be at position 1/offset 0

for a V[B] record the first <userdata> byte will be at position 5/offset 4
( position 1/offset 0 will contain the RDW - 4 bytes )
Back to top
View user's profile Send private message
Skolusu

Senior Member


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

PostPosted: Fri Sep 03, 2010 10:23 pm    Post subject:
Reply with quote

vicharapusrinu wrote:
Skolusu,

Thanks for providing solution,

Could you please let me know what would be changes in sort cart if my input data set is VB?


Regards,
Srini.


vicharapusrinu,


http://ibmmainframes.com/viewtopic.php?p=248417#248417
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Removing Duplicates based on certain ... chandracdac DFSORT/ICETOOL 8 Fri Dec 09, 2016 4:40 am
No new posts Limit duplicate records in the SORT pshongal SYNCSORT 6 Mon Nov 21, 2016 12:54 pm
No new posts FTP - JCL failed while passing FTP co... Suneetha1612 JCL & VSAM 12 Wed Nov 16, 2016 7:33 pm
No new posts TOT & DATE parameter in ICEMAN hemanthj642 DFSORT/ICETOOL 4 Mon Nov 14, 2016 5:19 am
This topic is locked: you cannot edit posts or make replies. How to pass the previous month date i... Suganya87 DFSORT/ICETOOL 5 Mon Oct 31, 2016 4:13 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us