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

Creating filelist ps file


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

New User


Joined: 12 Aug 2021
Posts: 1
Location: United States

PostPosted: Thu Aug 12, 2021 6:01 am
Reply with quote

HI

I need some help in jcl where we have a 100's of datasets and we receive one every week. We need to load the last 30 ps dataset names into another ps dataset. Our etl program uses a filelist to read the names of the datasets and load those 30 datasets into the database.

Dataset names

PDABC.BJHGY.F123.T001
PDABC.BJHGY.F123.T002
PDABC.BJHGY.F123.T003
PDABC.BJHGY.F123.T004
PDABC.BJHGY.F123.T005
PDABC.BJHGY.F123.T006
.....
PDABC.BJHGY.F123.T100


Put names Into this PS
BJHGV.ABCD.F123.FILELIST

Thanks,
Chamajid
Back to top
View user's profile Send private message
Willy Jensen

Active User


Joined: 01 Sep 2015
Posts: 495
Location: Denmark

PostPosted: Thu Aug 12, 2021 2:05 pm
Reply with quote

You cannot do it just in JCL.
The solution depends on whether you are ok with entering the datasetnames yourself, in which case you can use ISPF 3.4 to list the datasetnames and cut/paste to the list dataset. Or save the entire list and edit the generated dataset.
Otherwise you need a program. REXX springs to mind as you can easily do a LISTCAT to get the names and generate the list.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 2771
Location: NYC,USA

PostPosted: Thu Aug 12, 2021 4:09 pm
Reply with quote

ibmmainframes.com/about42452.html
I would try with LISTCAT then use DFSORT to include just the name.
ibmmainframes.com/about34669.html
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
This topic is locked: you cannot edit posts or make replies. Sort to include records of file 2 int... Java & MQSeries 1
No new posts How to modify file content using REXX CLIST & REXX 3
No new posts VB file copy COBOL program gives erro... COBOL Programming 3
No new posts SORT for dynamic trailer record + CSV... DFSORT/ICETOOL 14
No new posts Merge a variable number of records fr... DFSORT/ICETOOL 5
Search our Forums:

Back to Top