Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Cics vsam - different layouts

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CICS
View previous topic :: :: View next topic  
Author Message
akshaiya

New User


Joined: 17 Sep 2005
Posts: 49

PostPosted: Thu Mar 22, 2007 1:04 am    Post subject: Cics vsam - different layouts
Reply with quote

I have a requirement that based on 2 different types in the vsam,i need to display the data in the screen.

VSAM-1 layout (type-1 on 23rd position)
VSAM-2 layout (type-2 on 23rd position)

Code:
*            ******************************************
*                      CICS OPERATION READ
*                     ******************************************
     EXEC CICS READ
         DATASET ( 'CMSVSAMC' )
         RIDFLD  ( IDGCA-VSAM-KEY )
         INTO    ( IDGCA )
         LENGTH  ( IDGCA-LENGTH )
         END-EXEC.


After read,
if it is found that the record is type-1 then I need to put in VSAM-1 Layout
if it is found that the record is type-2 then I need to put in VSAM-2 Layout

can you tell me how do we this in cics.
Back to top
View user's profile Send private message

Mickeydusaor

Active User


Joined: 24 May 2006
Posts: 258
Location: Salem, Oregon

PostPosted: Thu Mar 22, 2007 1:32 am    Post subject:
Reply with quote

create 2 seperate maps within your mapset and then display the map that is for the correct vsam layout
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Thu Mar 22, 2007 1:40 am    Post subject:
Reply with quote

Personally, I'd READ SET and once I've determined which type then I'd move (ws) or set address (linkage).
Back to top
View user's profile Send private message
GlobalGyan

New User


Joined: 31 Jan 2006
Posts: 28

PostPosted: Thu Mar 22, 2007 10:03 am    Post subject:
Reply with quote

I belive you have a variable length file. The length LENGTH ( IDGCA-LENGTH ) usually in this case is the maximum length of a record in the VSAM file. After pushing into the IDGCA field, you can check for the type and then move to the corresponding WS VSAM layouts.

- GG
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 -> CICS All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts how to recover an uncataloged VSAM da... archanamuthukrishnan All Other Mainframe Topics 3 Wed Jan 11, 2017 6:18 pm
No new posts Underlying DB2 VSAM LDS - SMF recording vasanthz All Other Mainframe Topics 6 Thu Jan 05, 2017 4:20 am
No new posts INDEPENDENT CICS TS 4.1 MRO REGION UP... Kyle Carroll CICS 0 Wed Dec 14, 2016 6:55 pm
No new posts CICS START AND CANCEL blayek CICS 1 Wed Dec 07, 2016 3:27 am
No new posts How does a called pgm know if its cal... Graeme Westerman COBOL Programming 4 Tue Nov 29, 2016 9:25 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us