MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

&DATE2

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities
View previous topic :: View next topic  
Author Message
prgaj1
Beginner


Joined: 01 Jul 2003
Posts: 6
Topics: 5
Location: Pennsylvania, USA

PostPosted: Wed Jul 09, 2008 2:58 pm    Post subject: &DATE2 Reply with quote

Hi,
I have a file which with data for seven years. Yearly I change my sort parameter to only get the last two years data. I was wondering if I could use &DATE to prevent remembering to change the parameters.
Currently the Sort Parameter look as follow:
PARM CURRENT:
Code:

 OMIT      COND=(06,02,CH,EQ,C'00',OR, 
                 06,02,CH,EQ,C'06',OR, 
                 06,02,CH,EQ,C'05',OR, 
                 06,02,CH,EQ,C'04',OR, 
                 06,02,CH,EQ,C'03',OR, 
                 06,02,CH,EQ,C'02',OR, 
                 06,02,CH,EQ,C'01')   

I cannot change it as follow since I must omit data for the previous 2 years not 24 months
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12376
Topics: 75
Location: San Jose

PostPosted: Wed Jul 09, 2008 4:15 pm    Post subject: Reply with quote

prgaj1,

You cannot comapre &date2-m to Y2T date format. however you can add &Date2-24 at the end of every record and compare it.

Assuming your input file is FB and 80 byte lrecl

You can use the following DFSORT control cards

Code:


//SYSIN    DD *                                     
  SORT FIELDS=COPY                                   
  OUTREC OVERLAY=(81:&DATE2-24)                     
  OUTFIL BUILD=(1,80),INCLUDE=(3,4,Y2T,GE,83,4,Y2T) 
//*                                                 


Hope this helps...

Cheers
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
prgaj1
Beginner


Joined: 01 Jul 2003
Posts: 6
Topics: 5
Location: Pennsylvania, USA

PostPosted: Thu Jul 10, 2008 9:26 am    Post subject: Reply with quote

I get an syntax error on the &date2 not sure why as it show a similiar example in the manual..
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12376
Topics: 75
Location: San Jose

PostPosted: Thu Jul 10, 2008 10:14 am    Post subject: Reply with quote

prgaj1,

You need to show us the sysout messages to be able to help you.

Kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group