Smart questions
Smart answers
Smart people
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Member Login

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips now!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

Join Tek-Tips
*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

LINK TO THIS FORUM!

Add Stickiness To Your Site By Linking To This Professionally Managed Technical Forum.
Just copy and paste the
code below into your site.

Partner With Us!

"Best Of Breed" Forums Add Stickiness To Your Site
Partner Button
(Download This Button Today!)

Feedback

"...I have been a grateful member of this site for several years. I love this site and refer everyone to it!..."

Geography

Where in the world do Tek-Tips members come from?
janegee (Programmer)
16 Mar 03 18:14
I am a recent convert from Roscoe RPF language- trying to write an OS390 rexx that reads in a pds member consisting of dsn's one line after another. Then the rexx exec would insert two static lines of information after each dsn. So every third line would now be the dsn. I know there is a simple way to edit data. Would someone be willing to send an example. I promise when I master Rexx, I will do the same in kind. Thank you! Joan
kevinf2349 (TechnicalUser)
17 Mar 03 9:15
This is how I do it.

I have a member of a dataset that contains dataset names. Then I do the following

address ISPEXEC "EDIT DATASET('"sysuid".CLIST.MSTR(XMITLIST)')"
"ALLOC F(XMITDSNS) DA('"sysuid".CLIST.MSTR(XMITLIST)') SHR REUSE"
"EXECIO * DISKR XMITDSNS (STEM LINE. FINIS"                 
DO I = 1 TO line.0                                          
      line = strip(line.i)                                  
      say line.i
end

Of course instead of the 'say line.i' you replace that with any logic that you need performed against each line. In my case I usually check that the dataset name exists and then I TSO XMIT them for downloading to PC.

Hope this helps
rexxhead (Programmer)
17 Mar 03 12:46
Input dataset contains -n- lines; output is all input lines each followed by two lines of static information....


address TSO
"ALLOC FI($TMP) DA("input_dsn") SHR REU"
"NEWSTACK"
"EXECIO * DISKR $TMP (FINIS"
do queued()
   parse pull line
   queue line
   queue "Static line #1"
   queue "Static line #2"
end  /* queued */
"EXECIO" queued() "DISKW $TMP (FINIS"
"DELSTACK"
"FREE  FI($TMP)"

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Back To Forum

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close