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 Member


Joined: 01 Sep 2015
Posts: 712
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: 3053
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
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
Search our Forums:

Back to Top