Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Forum Index
 
Register
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
working with Copybooks

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
anirudh1985
Currently Banned

New User


Joined: 22 Aug 2007
Posts: 66
Location: bangalore

PostPosted: Mon Jun 16, 2008 3:07 pm    Post subject: working with Copybooks
Reply with quote

Hi,

I have a copybook or a record structure from which i need to obtain the field names and the corresponding PIC values. How can this be achieved.

Ex: 01 emp-record.
05 name pic x(5)
05 city pic x(10)
05 country pic x(10)
My output should be:
name 5
city 10
country 10

Please help me out.....
Back to top
View user's profile Send private message

ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Mon Jun 16, 2008 3:19 pm    Post subject:
Reply with quote

If you have FileAid, RLPRINT is your answer...

O.
Back to top
View user's profile Send private message
anirudh1985
Currently Banned

New User


Joined: 22 Aug 2007
Posts: 66
Location: bangalore

PostPosted: Mon Jun 16, 2008 3:40 pm    Post subject:
Reply with quote

ofer71 wrote:
If you have FileAid, RLPRINT is your answer...

O.


i dont have fileaid... i should somehow copy them in stem variables
Back to top
View user's profile Send private message
enrico-sorichetti

Senior Member


Joined: 14 Mar 2007
Posts: 10696
Location: italy

PostPosted: Mon Jun 16, 2008 3:40 pm    Post subject: Reply to: working with Copybooks
Reply with quote

use the same approach as in ...
http://www.ibmmainframes.com/viewtopic.php?p=137555&highlight=#137555
http://www.ibmmainframes.com/viewtopic.php?p=137486&highlight=#137486
which Yourself started some time ago


and please stop asking repeatedly about the same issue
Back to top
View user's profile Send private message
anirudh1985
Currently Banned

New User


Joined: 22 Aug 2007
Posts: 66
Location: bangalore

PostPosted: Mon Jun 16, 2008 4:00 pm    Post subject:
Reply with quote

this is not the same issue ...i guess you are finding problems with understanding the requirements.......This forum should be a healthy forum where people help others to solve the problems or assist them....This is however not pretty visible in your answers. kindly understand the problem a person undergoes while submitting queries and dont do a mockery
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


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

PostPosted: Mon Jun 16, 2008 5:04 pm    Post subject:
Reply with quote

anirudh1985 wrote:
this is not the same issue ...i guess you are finding problems with understanding the requirements.......This forum should be a healthy forum where people help others to solve the problems or assist them....This is however not pretty visible in your answers. kindly understand the problem a person undergoes while submitting queries and dont do a mockery


No problem understanding your issues. For someone asking for help I think some sign of more thinking and less flaming would be wise.
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1079
Location: Dublin, Ireland

PostPosted: Mon Jun 16, 2008 5:47 pm    Post subject:
Reply with quote

I must say the requirements do look like the same issue to me.
However, the OP could probably meet the requirement by first using the cobdfsym REXX program (DFSORT) which can be found at https://www-304.ibm.com/systems/support/storage/software/sort/mvs/tricks/pdf/sorttrck.pdf

Given a compile listing of the COPYBOOK, this gives the field name, start-pos and length for fields. Extracting the first and third parameters from the output should give him pretty much what he wants.


Regards,

Garry.
Back to top
View user's profile Send private message
dick scherrer

Site Director


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

PostPosted: Mon Jun 16, 2008 8:43 pm    Post subject:
Reply with quote

Hello,

Quote:
this is not the same issue
Yes, it is. This question is just like your "other" (same) question. The only difference is that this one is a bit more simple than the other.

Unless, you have not described what you want clearly. . .

If you already have something that will give you the length and displacement of the fields in a copybook, why can you not use it to get only the length?
Back to top
View user's profile Send private message
mbizzle

New User


Joined: 06 May 2020
Posts: 7
Location: United States

PostPosted: Wed May 06, 2020 6:55 pm    Post subject:
Reply with quote

I registered just so I could share this fix to COBDFSYM.

I had been using it for a few years now, and loved it and was sad when our upgrade from cobol compiler V4 to V6 bricked this program. Luckily, it was a fairly simple fix to update it.
Here are the fixes you need to make to allow it to be compatible with the V6 (and i assume V5) compilers.
I am posting this on a few forums so that others may find it that have the same issue.

change this line
parse var line 92 asmdef datatyp .
to
parse var line 87 asmdef datatyp .

and add this line

do until left(line,1) = '1'
call Put_line
parse pull line
if pos('End of Data Division Map',line)<> 0 then leave
end
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. Invoke REXX thru JCL to expand the co... spizen556 CLIST & REXX 2 Sun Jul 26, 2020 3:53 pm
No new posts On a team working on a new project fo... zCMHII All Other Mainframe Topics 2 Mon Apr 06, 2020 9:15 pm
No new posts How efficient are you, while working ... vasanthz General Talk & Fun Stuff 0 Tue Mar 31, 2020 11:39 pm
No new posts Large'ish Working Storage and SOS issues govindc CICS 0 Sat Jan 18, 2020 1:58 am
No new posts DSLIST Command is not working thesumitk TSO/ISPF 14 Mon Dec 10, 2018 8:10 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us