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

Define combination of two fields as a key in vsam ksds


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
vishalbshah

New User


Joined: 01 Dec 2006
Posts: 61
Location: Pune

PostPosted: Fri Dec 01, 2006 3:41 pm
Reply with quote

[quote]
This is my record structure

01 INTERFACE-RECORD.
05 ACCOUNT-NUMBER PIC X(17).
05 ACCOUNT-TYPE PIC X(03).
05 ICS-TRAN-CODE PIC 9(06).
05 TRANS-AMOUNT PIC 9(08)V99.
05 ICS-SEQUENCE-NUMBER PIC 9(10).

This is a flat file and i want make one vsam with
ACCOUNT-NUMBER and ICS-SEQUENCE-NUMBER as a key how can i write two lengths and two offsets in the KEYS parameter while defining a cluster. [/b]
Back to top
View user's profile Send private message
mallikannasagaram

New User


Joined: 21 Feb 2006
Posts: 9
Location: india

PostPosted: Fri Dec 01, 2006 3:56 pm
Reply with quote

If changing of the record layout is OK then move the required fields together from the first (move ICS-SEQUENCE-NUMBER to the 2 colum in your record layout) and specify key as total length of two fields(27bytes). This fulfills yourrequirement.



Regards,
Mallik
Back to top
View user's profile Send private message
William Thompson

Global Moderator


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

PostPosted: Fri Dec 01, 2006 4:00 pm
Reply with quote

He's right, no split keys allowed.
Back to top
View user's profile Send private message
vishalbshah

New User


Joined: 01 Dec 2006
Posts: 61
Location: Pune

PostPosted: Fri Dec 01, 2006 5:38 pm
Reply with quote

Hi Malik,

i thought of this way i just wanted to know if any other option is possible so as you are saying no split keys allowed the i left with only one option.
that is same as you suggest

Thanks,
Vishal
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Access to non cataloged VSAM file JCL & VSAM 18
No new posts DTL - how to define key with stacked ... TSO/ISPF 3
No new posts Merge two VSAM KSDS files into third ... JCL & VSAM 6
No new posts CVDA value for RRDS VSAM dataset. CICS 2
No new posts VSAM return code 23 - for a Random read COBOL Programming 4
Search our Forums:

Back to Top