IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

IDCAMS - Filtering data on columns for PS files like SORT


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
sayferoz

New User


Joined: 10 Feb 2013
Posts: 1
Location: India

PostPosted: Fri Mar 15, 2013 9:01 pm
Reply with quote

Hi All,
Hope life is busy in enjoying work and personal life.
My requirement is generate file name (like PAB.DYYMMDD will be PAB.D130101) and filter records for a particular account from it. This I am doing in two steps:

Step 1: Use IDCAMS IDS('Dynamically generated file name') and copy it another OUT file
Step 2: Give OUT file as input to SORT and filter them based on account number and date.
This is working perfectly fine. Only issue is that file contains more than 200M records and I have to process 10-12 such files, which is cubersome from resources point of view.

How can I achieve my requirement in single IDCAMS or SORT / ICETOOL Process? Can I supply dynamically generated file name to SORT as like I am doing STEP 1 or can I use IDCAMS to filter records like SORT?

One option could be generating dynamic JCL in COBOL or use INTRDR which I can't do due to limitation of site.
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1788
Location: Bloomington, IL

PostPosted: Fri Mar 15, 2013 9:14 pm
Reply with quote

Can you use the SUBMIT command from background TSO?
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Sat Mar 16, 2013 2:05 am
Reply with quote

Perhaps investigate dynamic file allocation with Cobol, and an "EXIT" program (which can be in Cobol) for your Sort product.

Sort can read and format, with the EXIT doing the output itself.

Perhaps you could even have an input EXIT, which allocates the dynamic DSN for SORTOUT, but with a COPY operation maybe the SORTOUT is already open.

Perhaps, then, look at doing an "internal SORT" in Cobol, where you allocate the DSN before doing the SORT. Ensure that you have compiler option FASTSRT and obey the manual for how to code the SORT to ensure that SORT does all the IO. This could work for DFSORT, but you'd have to check your SyncSort documentation if that is what you have.

If you want to consider this route, tell us which SORT product you have and the topic can be moved to the DFSORT or JCL (if SyncSort) forum.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Write line by line from two files DFSORT/ICETOOL 7
No new posts Compare only first records of the fil... SYNCSORT 7
No new posts Data set Rec-Cnt and Byte-Cnt Testing & Performance 2
No new posts JCL sort card - get first day and las... JCL & VSAM 9
Search our Forums:

Back to Top