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

Write data in tabular format


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

New User


Joined: 22 Jan 2008
Posts: 85
Location: India

PostPosted: Sun Sep 28, 2008 9:07 am
Reply with quote

Hi ,
I have a requirement like this, in a ps file i have data like

Mamber name=Member1
Jobname.1=aaaaa
program name.1=ikj**
programe name.2=PROC
Programe name.3=IEBR
stepname.1=STEP1
stepname.2=STEP2

Mamber name=Member2
Jobname.1=bbbbb
program name.1=ikj**
programe name.2=PROC1

Now, i have to write these data in a tabular format in rexx, some thing like this,

Jobname********Programe name****stepname
aaaaa*********** ikj**************STEP1
**************** PROC ***********STEP2
**************** IEBR
Please leave the asteriks and see it as a table
Can you please tell me how to write the data in tabular format.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sun Sep 28, 2008 9:47 am
Reply with quote

Hello,

What should be done with "member name"? Does it not go to the "output"? Is there a maximum to how many steps/programs you want to allow? SHould there be the same number of steps as programs in a "job"?

You need to continue the "output" to include member2. Where do you plan to write the output (report, another file)?

When you post the complete info, please use the "Code" tag at the top of the reply panel. Then you will not need the asterisks. Use Preview to see your post as the forum will see it rather than how it appears in the reply editor. When the Preview appears as you want it, click Submit.

If you are doing this with clist or rexx, post what you have so far. If you are not using clist/rexx, post how you are dong this and the topic will be moved to some other part of the forum.
Back to top
View user's profile Send private message
Marso

REXX Moderator


Joined: 13 Mar 2006
Posts: 1353
Location: Israel

PostPosted: Sun Sep 28, 2008 9:04 pm
Reply with quote

Indeed, your question raises a few more questions...

Do you want data like this?
Code:
Jobname    Progname    stepname
aaaaa      ikj         STEP1
           PROC        STEP2
           IEBR


If yes, an easy way is:
Code:
Left(Jobname.xj,12) || Left(Progname.xj,12) || Left(Stepname.xj,8)
Back to top
View user's profile Send private message
awyn

New User


Joined: 11 Feb 2008
Posts: 49
Location: chennai

PostPosted: Mon Sep 29, 2008 9:46 am
Reply with quote

Hi,
The stem variable gets updated for each member.I mean when it is for member1 by jobname , program name , step name will be like
jobname.1 , program name.1 , step name.1
again when i encounter member2,
again my varaiables get updated jobname.1 , program name.1 , step name.1, how do i write now in my output file.
Back to top
View user's profile Send private message
Pedro

Global Moderator


Joined: 01 Sep 2006
Posts: 2546
Location: Silicon Valley

PostPosted: Mon Sep 29, 2008 9:18 pm
Reply with quote

This is confusing:
Quote:
again when i encounter member2,
again my varaiables get updated jobname.1 , program name.1 , step name.1,


Based on the accompanying text, you should have updated jobname.2 and program.name.2, etc... please clarify.
Back to top
View user's profile Send private message
Pedro

Global Moderator


Joined: 01 Sep 2006
Posts: 2546
Location: Silicon Valley

PostPosted: Mon Sep 29, 2008 9:38 pm
Reply with quote

I think your 'tags' will cause you some confusion (as it did to me):
Code:
Mamber name=Member1
Jobname.1=aaaaa
program name.1=ikj**
programe name.2=PROC
Programe name.3=IEBR
stepname.1=STEP1
stepname.2=STEP2


Confusing because they have numeric value that might be mistaken for an index value. I suggest you use program variables that also include the numeric suffix, in addition to your own indexing. For example:
Code:
idx = 2
say stepname.1.idx


[/code]
Back to top
View user's profile Send private message
awyn

New User


Joined: 11 Feb 2008
Posts: 49
Location: chennai

PostPosted: Mon Oct 06, 2008 9:24 am
Reply with quote

thanks lot. i got it
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 Populate last day of the Month in MMD... SYNCSORT 2
No new posts Modifying Date Format Using DFSORT DFSORT/ICETOOL 9
No new posts Write line by line from two files DFSORT/ICETOOL 7
No new posts Data set Rec-Cnt and Byte-Cnt Testing & Performance 2
No new posts SCOPE PENDING option -check data DB2 2
Search our Forums:

Back to Top