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
 

 

Sort on Date Ranges.

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

New User


Joined: 01 Jul 2010
Posts: 5
Location: india

PostPosted: Tue Jul 06, 2010 1:15 pm    Post subject: Sort on Date Ranges.
Reply with quote

Hi,

I want to know if it is possible to use Sort Cards to get data based on date range.
I have a file which is having date as one of the fields, based on that i have to filter records occuring in the last three months, six months and last one year.
i got one sort from this forum ,&DATE1(-)), ,&DATE1(-)-61 but it does not take into account 30 and 31 days for different months
Back to top
View user's profile Send private message

Skolusu

Senior Member


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

PostPosted: Tue Jul 06, 2010 11:34 pm    Post subject:
Reply with quote

santoshn,

1. What is the LRECL and RECFM of the input and output files?
2. What is the position and format of the date field you trying to validate?
3. When you say 3 months and 6 months , can you just account the month portion? like current month is july , last 3 months would start from apr and 6 months would start from feb. Do you need to go to specific date ?

Last but not least, run the following job and show me the entire sysout which helps us determine the level of DFSORT your shop has

Code:

//STEP0100 EXEC PGM=SORT   
//SYSOUT   DD SYSOUT=*     
//SORTIN   DD *           
A                         
//SORTOUT  DD SYSOUT=*     
//SYSIN    DD *           
  SORT FIELDS=COPY         
//*
Back to top
View user's profile Send private message
santoshn

New User


Joined: 01 Jul 2010
Posts: 5
Location: india

PostPosted: Fri Jul 09, 2010 10:34 pm    Post subject:
Reply with quote

Hi,
1.) I have an 80 bytes FB file.
2.) The format of date field is tweakable. As of now it is ccyy/mm/dd. the sort will run on 1 st of every month so is is to be from 1st day of every month to last day of the previous month.

i will upload sysout details tommorow.


Thanks
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 SORT to unpack a feild shr_amar DFSORT/ICETOOL 7 Fri Jul 07, 2017 4:32 am
No new posts How to add header with Date(YYMMDD) i... Rajan Moorthy DFSORT/ICETOOL 2 Thu Jul 06, 2017 11:44 pm
No new posts How to write Specific Fields from Mul... Padhu SYNCSORT 6 Thu Jul 06, 2017 10:26 am
No new posts Optimize sort inrec parse vishwakotin DFSORT/ICETOOL 6 Mon Jun 26, 2017 11:15 pm
No new posts Reduce CPU Times for Join Sort santoshn SYNCSORT 12 Sat Jun 10, 2017 1:40 pm


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