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

REXX to find /* Define and write the next 9 lines


IBM Mainframe Forums -> CLIST & REXX
Post new topic   This topic is locked: you cannot edit posts or make replies.
View previous topic :: View next topic  
Author Message
markzasz

New User


Joined: 04 Apr 2017
Posts: 9
Location: USA

PostPosted: Fri Jun 11, 2021 4:22 pm
Reply with quote

Hello,

I have a datasets that contains 22 millions lines and 450,000 IDCMAS Define statements along with many other commands. I would like to scan the dataset and create multiple output files that contain the Define statements based on the usercatalog.

my defines look like this in the dataset.

/* DEFINE -
NONVSAM( -
NAME(PCMSS.MS3AT.EXTRACT.INDX.BASE.G0001V00) -
RECATALOG -
VOLUMES(MG4W12) -
DEVICETYPES(3390) -
) -
CATALOG(CATALOG.DZOSPLX.PROD05);

So when you find "/* DEFINE"
- save DEFINE and the next 7 lines
- and write the saved info to one of five output files.

the reason for five output files is we have 5 User Catalogs that these defines are going to and we would like to break the defines up by User Cataloag.

Thank you,

Mark...
Back to top
View user's profile Send private message
Joerg.Findeisen

Senior Member


Joined: 15 Aug 2015
Posts: 1338
Location: Bamberg, Germany

PostPosted: Fri Jun 11, 2021 4:30 pm
Reply with quote

Consider using a SORT product for this mass data processing, more fun.
Back to top
View user's profile Send private message
Pete Wilson

Active Member


Joined: 31 Dec 2009
Posts: 592
Location: London

PostPosted: Fri Jun 11, 2021 6:48 pm
Reply with quote

This seems a very odd thing to do unless perhaps you're cloning the volumes and making them available on other Sysplexes or VM Z/OS guests or something.

Trying to catalog the 'same' physical dataset, as implied by volser being coded, in 4 different catalogs on the same Sysplex? I'm not even sure it would be possible if they're SMS managed because the catalog backward pointer in the datasets NVR record in the volumes VVDS can only point to one catalog, which would get a mismatch during RECATALOG processing if a different catalog was specified.
Back to top
View user's profile Send private message
markzasz

New User


Joined: 04 Apr 2017
Posts: 9
Location: USA

PostPosted: Fri Jun 11, 2021 6:52 pm
Reply with quote

I am not cloning the same dataset, i have a dataset with 25 million lines of IDCMAS statements created by a TACM Program, in this dataset i have 492,000 IDCAMS Define statements i would like to extract and place in a separate dataset that only contains the IDCAMS Define statements.

So one dataset with 492,000 of these.....

DEFINE -
NONVSAM( -
NAME(PCMSS.MS3AT.EXTRACT.INDX.BASE.G0001V00) -
RECATALOG -
VOLUMES(MG4W12) -
DEVICETYPES(3390) -
) -
CATALOG(CATALOG.DZOSPLX.PROD05);
Back to top
View user's profile Send private message
jerryte

Active User


Joined: 29 Oct 2010
Posts: 203
Location: Toronto, ON, Canada

PostPosted: Fri Jun 11, 2021 7:23 pm
Reply with quote

Try using SuperSearch (ispf option 3.15). Set process option LPSF which will list lines before and after a find. Then define and edit a Statements DSN and code a "LPSFV 7" to specify lines instead of the default 6. Using the results from this you can then process with a Rexx.
NOTE: the EXECIO cannot read a large quantity of lines. You will need to put inside a loop and process maybe 1000 lines at a time. Good luck.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


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

PostPosted: Fri Jun 11, 2021 7:26 pm
Reply with quote

Mark Zaszczurynski, Please don't post twice the same question under different section.
ibmmainframes.com/viewtopic.php?p=352327#352327
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   This topic is locked: you cannot edit posts or make replies. View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CLIST & REXX

 


Similar Topics
Topic Forum Replies
No new posts Run rexx with JCL Job CLIST & REXX 1
No new posts Run rexx in batch job CLIST & REXX 7
No new posts Does anyone know rexx for VSE CLIST & REXX 3
No new posts TSO ALLOC In REXX Needs Improvement JCL & VSAM 3
No new posts REXX/CMS How to place command console... CLIST & REXX 4
Search our Forums:

Back to Top