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
 

 

Using EZtrieve to fetch a record in a KSDS VSAM file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CA Products
View previous topic :: :: View next topic  
Author Message
thilakvs
Warnings : 1

New User


Joined: 07 Aug 2007
Posts: 27
Location: chennai

PostPosted: Wed Aug 29, 2007 11:39 am    Post subject: Using EZtrieve to fetch a record in a KSDS VSAM file
Reply with quote

Using EZtrieve to fetch a record in a KSDS VSAM file...how can we do this..?
Back to top
View user's profile Send private message

rsm143

New User


Joined: 29 May 2007
Posts: 4
Location: india

PostPosted: Wed Aug 29, 2007 5:36 pm    Post subject: Reply to: Using EZtrieve to fetch a record in a KSDS VSAM fi
Reply with quote

hit the vsam file with there key
then move required varibales in ur ws section .........

this is a small example ... in this program a filed is updating
which is key of vsam table
**************************************************

//S010EZT EXEC PGM=EZTPA00,COND=(0,NE,STEP001)
//SYSPRINT DD SYSOUT=*
//EZTVFM DD UNIT=SYSDA,SPACE=(CYL,(10,10),RLSE)
//SYSOUT DD SYSOUT=*
//PFTABLE DD DSN=MPMT.PROD.PFTABLE,DISP=SHR
//SYSIN DD *
FILE TABLE VS UPDATE
XXX-REC 1 200 A
XXXT-KEY 1 20 A
XXXT-ENTITY 1 3 A
XXXT-TBL-IND 4 9 A
XXXT-TBL-VALUE 13 8 A
XXXT-SHORT-DESC 21 10 A
XXXT-LONG-DESC 31 30 A

WS-XXX-REC W 200 A
WS-XXXT-TBL-VALUE WS-XXX-REC +12 8 A
WS-XXXT-SHORT-DESC WS-XXX-REC +20 10 A
WS-XXXT-LONG-DESC WS-XXX-REC +30 30 A

JOB INPUT NULL

XXXT-ENTITY = '1 '
XXXT-TBL-IND = 'TRAN_TYPE'
XXXT-TBL-VALUE = '454 '
READ PFTABLE KEY XXXT-KEY STATUS
IF FILE-STATUS(PFTABLE) EQ 0
DISPLAY 'READ SUCCESSFULL'
WS-XXX-REC = XXX-REC
WRITE PFTABLE DELETE STATUS
IF FILE-STATUS(PFTABLE) EQ 0
DISPLAY 'DELETE SUCCESSFULL'
END-IF
WS-XXXT-TBL-VALUE = '458 '
XXX-REC = WS-XXX-REC
WRITE PFTABLE ADD STATUS
WS-XXXT-TBL-VALUE = '454 '
XXX-REC = WS-XXX-REC
WRITE PFTABLE ADD STATUS
END-IF

IF FILE-STATUS(PFTABLE) EQ 00
DISPLAY 'UPDATE SUCCESSFULL'
ELSE
DISPLAY 'ERROR IN WRITING VSAM'
DISPLAY 'VSAM STATUS' FILE-STATUS(PFTABLE)
END-IF
STOP
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 -> CA Products All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Converting Variable block file to Fix... bhavana yalavarthi DFSORT/ICETOOL 10 Tue May 16, 2017 2:20 pm
No new posts Adding big TEXT lines to each record ... bshkris SYNCSORT 4 Sat May 06, 2017 1:40 am
No new posts Getting error while opening a variabl... apandey1 COBOL Programming 5 Fri May 05, 2017 12:22 pm
This topic is locked: you cannot edit posts or make replies. Merge two files and update Trailer re... Yashashri JCL & VSAM 1 Thu May 04, 2017 12:54 pm
No new posts Issue with NDM process to transmit ES... chetanambi All Other Mainframe Topics 6 Wed May 03, 2017 10:52 am


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