How to SORT data from input when it is in YY/MM/DD format



Support for NetApp SyncSort for z/OS, Visual SyncSort, SYNCINIT, SYNCLIST and SYNCTOOL

How to SORT data from input when it is in YY/MM/DD format

Postby N J Baruah » Wed Apr 04, 2018 10:42 pm

Hi All,

I am trying to sort data from an input file based on the reference date present in it from column 55 to 62. My requirement is to sort out data which has been last referenced within 3 months.

Please note that the reference date is present in the format YY/DD/MM (e.g: 18/03/14 etc).

I have tried the below sort code but it works only when the date format is YYYY/MM/DD. But I need to sort out the data from the input file which is present in the format YY/DD/MM and was last referenced within 3 months. So can anyone please help me with this.
--------------------------------------------------------------------------------
//SYSIN DD *
SORT FIELDS=COPY
INCLUDE COND=(55,8,CH,GT,DATE1(-)-90)
/*

--------------------------------------------------------------------------------
Coded for you - do it yourself next time
N J Baruah
 
Posts: 12
Joined: Wed Apr 04, 2018 6:02 pm
Has thanked: 1 time
Been thanked: 0 time

Re: How to SORT data from input when it is in YY/MM/DD format

 

Re: How to SORT data from input when it is in YY/MM/DD forma

Postby NicC » Wed Apr 04, 2018 11:39 pm

You need to sort yourself out - the title says the date is YY/MM/DD but your post says YY/DD/MM. If it is the latter then sort on 55 for 2, 61 for 2 and 58 for 2.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2812
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 116 times

Re: How to SORT data from input when it is in YY/MM/DD forma

Postby N J Baruah » Thu Apr 05, 2018 10:35 am

correction Nic.... it is YY/MM/DD
N J Baruah
 
Posts: 12
Joined: Wed Apr 04, 2018 6:02 pm
Has thanked: 1 time
Been thanked: 0 time

Re: How to SORT data from input when it is in YY/MM/DD forma

Postby N J Baruah » Thu Apr 05, 2018 9:37 pm

Hi All,

Can anyone please help me?
Your help will be really appreciated...


"I am trying to sort out data from an input file based on the reference date present in it from column 55 to 62. My requirement is to sort out data which has been last referenced within 3 months. Please note that the reference date is present in the format YY/MM/DD (e.g: 18/03/14 etc). "
N J Baruah
 
Posts: 12
Joined: Wed Apr 04, 2018 6:02 pm
Has thanked: 1 time
Been thanked: 0 time

Re: How to SORT data from input when it is in YY/MM/DD forma

Postby enrico-sorichetti » Thu Apr 05, 2018 11:09 pm

soliciting for answers is considered bad netiquette
and it will usually make people ignore the topic

remember ...
we reply on our own time and free of charge

if nobody replies it means that
nobody has an in depth knowledge of the topic
nobody is interested in answering
nobody likes You :mrgreen:
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2776
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 147 times

Re: How to SORT data from input when it is in YY/MM/DD forma

Postby Robert Sample » Fri Apr 06, 2018 1:51 am

Furthermore, your post mentions DATE1 but doesn't say if you've tried any of the D2? variables yet. If not, you need to look at them.
Robert Sample
Global moderator
 
Posts: 3524
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 251 times


Return to Syncsort/Synctool

 


  • Related topics
    Replies
    Views
    Last post