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

Help needed in searching word in first record of PDS member


IBM Mainframe Forums -> CLIST & REXX
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Satheeshkumar

New User


Joined: 20 Feb 2009
Posts: 51
Location: Chennai

PostPosted: Tue Feb 09, 2010 2:35 pm
Reply with quote

Hi,

I have to write A REXX tool to find the list of COBOL programs that do not have PROCESS cards in the programs(compiler option override The first word in first rec shold be PROCESS if the program has compiler option override)

Cobol source PDS: COMP.&app.&reg.SOURCE
where , &app an & Reg would be a input to the REXX tool.

The rexx tool has to search the word PROCESS in first record of every pds member. If process word is not found in the first record, the member name is written into the output file.

can anyone provide me the samp code.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Tue Feb 09, 2010 2:38 pm
Reply with quote

NO
this is a help forum, not a do it for me...
unless You/Your organization is willing to pay the proper fees
Back to top
View user's profile Send private message
Escapa

Senior Member


Joined: 16 Feb 2007
Posts: 1399
Location: IL, USA

PostPosted: Tue Feb 09, 2010 2:38 pm
Reply with quote

Quote:
can anyone provide me the samp code.

Why?

What have you tried till now? Where are you stuck?
Back to top
View user's profile Send private message
Escapa

Senior Member


Joined: 16 Feb 2007
Posts: 1399
Location: IL, USA

PostPosted: Tue Feb 09, 2010 2:43 pm
Reply with quote

Quote:

Posted: Tue Feb 09, 2010 2:38 pm Post subject: Reply to: Help needed in searching word in first recod of PD

--------------------------------------------------------------------------------

NO
this is a help forum, not a do it for me...
unless You/Your organization is willing to pay the proper fees
_________________
Regards
enrico sorichetti

Quote:

Posted: Tue Feb 09, 2010 2:38 pm Post subject:

--------------------------------------------------------------------------------

Quote:
can anyone provide me the samp code.

Why?

What have you tried till now? Where are you stuck?

Ohh.. what a .. active forum.. Mac might need to implement seconds part also... icon_lol.gif
Back to top
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Tue Feb 09, 2010 4:38 pm
Reply with quote

Get the values for app and reg from the user.

Get the directory listing of 'COMP.app.reg.SOURCE'.

Loop for each member:

Allocate the PDS and member. Read only 1 record. Look for the word PROCESS. If not found, push the member name to the data stack. Repeat.

End the loop. Write the data stack of member names to the output.
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 400
Location: Mumbai

PostPosted: Tue Feb 09, 2010 8:42 pm
Reply with quote

see the ISPF services LMMLIST and LMGET and the associated services you need to use them. Examples available in the docs and net. Alternative to LMGET is EXECIO. For a small task as this, either one is probably OK, but if there are thousands of members, then LMGET will be faster because you don't have to allocate the whole data set for each member.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Tue Feb 09, 2010 8:47 pm
Reply with quote

at first shot why not use a quick and dirty srchfor ??
it would be useful for an initial screening to evaluate the complexity of the issue and then decide on how to proceed!

I know I am boring,
but when a requirement defines also the tool, in this case REXX and ISPF EDIT MACRO
I wonder why nobody cares if the skill is available icon_eek.gif
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Tue Feb 09, 2010 9:10 pm
Reply with quote

CBL could be used instead of PROCESS and there may or may not be a sequence number.
Back to top
View user's profile Send private message
prino

Senior Member


Joined: 07 Feb 2009
Posts: 1306
Location: Vilnius, Lithuania

PostPosted: Tue Feb 09, 2010 11:17 pm
Reply with quote

Craq Giegerich wrote:
CBL could be used instead of PROCESS and there may or may not be a sequence number.


Yes, and?

SuperC can search for more than one string and it can handle sequence numbers...
Back to top
View user's profile Send private message
MFRASHEED

Active User


Joined: 14 Jun 2005
Posts: 186
Location: USA

PostPosted: Tue Feb 09, 2010 11:52 pm
Reply with quote

And also if your Shop has PDSMAN/EZYEDIT Facility, you can use SCAN to search for a string.
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 -> CLIST & REXX

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts PARSE Syntax for not fix length word ... JCL & VSAM 7
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts Search two or more word with FILEAID Compuware & Other Tools 15
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
Search our Forums:

Back to Top