Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
can we code occurs and redefines in the linkage section?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
sreenivasreddyg

New User


Joined: 23 Apr 2005
Posts: 39
Location: delhi

PostPosted: Sat Apr 23, 2005 10:13 am    Post subject: can we code occurs and redefines in the linkage section?
Reply with quote

hi,

can we code occurs and redefines in the linkage section?if i want to pass the table contents to a subprogram what method i should approach.

regards,
sreenivas
Back to top
View user's profile Send private message

mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Sun Apr 24, 2005 3:50 am    Post subject:
Reply with quote

Hi sreenivas,

I've never tried it, but I'm sure you can do it. But your ques leads me to beleive you're not looking at the situation properly.

How you define the passed data is not a concern. You can pass a table as an 01 or 05 level without an occurs. It's only important that the pgm that receives the data defines it w/an occurs clause. For example:

Caller pgm

ws sect.
01 tbl.
05 ent pic x(010) occcurs 5.

01 w-data pic x(050).

proc div.

call pgma using tbl.

Pgma

Link sect.

01 my-tbl.
05 my-ent pic x(010) occurs 5.

proc div using my-tbl.


The Caller pgm could have also sent you w-data. So long as the data was organized as a table it would have worked for you too.
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Speed-up/reduce CPU use of code prino PL/I & Assembler 0 Tue Sep 26, 2017 12:05 am
This topic is locked: you cannot edit posts or make replies. how to code for GDG in Rexx cvnlynn CLIST & REXX 13 Wed Aug 09, 2017 9:13 pm
This topic is locked: you cannot edit posts or make replies. rexx code to create a ps file Bharath Vikraman CLIST & REXX 4 Mon Aug 07, 2017 10:30 am
No new posts I want to retire TRX and use only Rex... Abhinav Sharma CLIST & REXX 6 Sat Jul 29, 2017 2:53 am
No new posts UNIT=AFF for Easytrieve code gandikk JCL & VSAM 7 Wed Jul 12, 2017 11:42 pm

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