Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Changing sort Card Dynamically

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

New User


Joined: 10 Jun 2015
Posts: 44
Location: India

PostPosted: Sat Aug 19, 2017 2:33 pm    Post subject: Changing sort Card Dynamically
Reply with quote

Hi All,

I have one input file(LRECl 80) from which i have to fetch data based on below condition

Code:
Sort fields=copy
INCLUDE COND=(1,4,CH,EQ,C'ABC1',OR,1,4,CH,EQ,C'ABC0')


But problem is these securities(4 bytes example ABC1,ABC0) are received dynamically in below format
Code:
ABC1
ABC0
ABC9
.
.
.


So i need to change my INCLUDE COND sort card dynamically based on number of securities received.

Appreciate if you can guide me in achieving this.
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10350
Location: italy

PostPosted: Sat Aug 19, 2017 2:43 pm    Post subject: Reply to: Changing sort Card Dynamically
Reply with quote

probably JOINKEY is the right way to do it
lots of examples around
Back to top
View user's profile Send private message
vickey_dw

New User


Joined: 10 Jun 2015
Posts: 44
Location: India

PostPosted: Mon Aug 21, 2017 12:05 am    Post subject: Reply to: Changing sort Card Dynamically
Reply with quote

Hi Enrico
It will be very helpful if you can guide how this can be achieved using joinkey?
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 1922
Location: UK

PostPosted: Mon Aug 21, 2017 3:24 pm    Post subject:
Reply with quote

If your first three characters are always the same then why not just select on those?
Back to top
View user's profile Send private message
magesh23586

Active User


Joined: 06 Jul 2009
Posts: 210
Location: Chennai

PostPosted: Mon Aug 21, 2017 8:50 pm    Post subject: Reply to: Changing sort Card Dynamically
Reply with quote

give us a sample input of both the files to suggest.
Back to top
View user's profile Send private message
sergeyken

Active User


Joined: 29 Apr 2008
Posts: 212
Location: Maryland

PostPosted: Wed Aug 23, 2017 9:57 pm    Post subject: Re: Reply to: Changing sort Card Dynamically
Reply with quote

vickey_dw wrote:
Hi Enrico
It will be very helpful if you can guide how this can be achieved using joinkey?


Code:
 JOINKEYS F1=MASTER,FIELDS=(1,4,A)     master file to select records from
 JOINKEYS F2=SELECTOR,FIELDS=(1,4,A)   selection file with allowed keys
 REFORMAT FIELDS=(F1:1,nnn)            choose only MASTER part
 ....
 END
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 JOINKEYS Paired and Unpaired Sort on ... MFwhiz DFSORT/ICETOOL 7 Tue Nov 07, 2017 2:46 am
This topic is locked: you cannot edit posts or make replies. Need help how to pass the ESP variabl... Venkichaitu JCL & VSAM 12 Thu Nov 02, 2017 3:53 am
No new posts sort records based on length exceeds ... maxsubrat DFSORT/ICETOOL 7 Wed Oct 04, 2017 4:48 pm
No new posts JOINKEYS Paired and Unpaired Sort MFwhiz DFSORT/ICETOOL 4 Fri Sep 29, 2017 1:48 am
No new posts Difference in SORT & ICETOOL Mohan Kothakota DFSORT/ICETOOL 5 Fri Sep 22, 2017 4:56 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us