How to declare the EMP Name, EMP No., DOB in VSAM KSDS
file? Please explain.....

Answers were Sorted based on User's Feedback



How to declare the EMP Name, EMP No., DOB in VSAM KSDS file? Please explain.......

Answer / gomathi

//PSTY0010 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
DEFINE CLUSTER (NAME (SAMPLE.DATA) -
TRACKS(45 15) -
RECORDSIZE(80 80) -
FREESPACE(10 15) -
KEYS(6 0) -
INDEXED) -
DATA (NAME(SAMPLE.DATA.DAT) -
CISZ(8192)) -
INDEX (NAME(SAMPLE.DATA.IDX))
/*
//*

In Key (6,0) mention the start position and length of the
key

Is This Answer Correct ?    11 Yes 5 No

How to declare the EMP Name, EMP No., DOB in VSAM KSDS file? Please explain.......

Answer / prachi

//STEP010 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
DEFINE CLUSTER (NAME (EMPLOYEE.INFO.FILE) -
VLOUMES(TSOP01) -
CYLINDERS(10,2) -
CONTROLINTERVALSIZE(4096) -
FREESPACE(10,20) -
KEYS(5,21) -
RECORDLENGHT(31,31) -
DATA -
(NAME(EMPLOYEE.INFO.FILE.DATA)) -
INDEX -
(NAME(EMPLOYEE.INFO.FILE.INDEX) -
CONTROLINTERVALSIZE(1024))
/*
//

ASSUMING FOLLOWING THINGS

EMP-NO AS KEY

EMP-NO PIC 9(5)
EMP-NAME PIC X(20)
DOB PIC X(6)

RECORD IS FIXED LENGHT

Is This Answer Correct ?    0 Yes 3 No

How to declare the EMP Name, EMP No., DOB in VSAM KSDS file? Please explain.......

Answer / shiva

Gomathi you are 100% correct..

Is This Answer Correct ?    1 Yes 5 No

Post New Answer

More VSAM Interview Questions

Define gdg?

0 Answers  


How is record management performed in vsam?

0 Answers  


What is the catalog?

1 Answers  


is it slower if you access a record through alternative index as compared to primary index?

1 Answers   IBM,


There are at least seven IDCAMS commands; name and explain each of them ?.

1 Answers  






What are the access method services used in vsam?

0 Answers  


If fspc(100 100) is specified does it mean that both the control interval and control area will be left empty because 100 % of both ci and ca are specified to be empty?

0 Answers  


Would you specify FREESPACE for an ESDS?

1 Answers  


When CISZ is declared as 4096 at cluster level,is this true that data will have 4096 and index will have default?????

1 Answers   Wipro,


what are the idcams commands that can be used for vsam and explain each of them.

0 Answers   IBM,


how many ways can we open i vsam file ? like print ch ids (/) is thre any other way to open the vsam file please can any one answer ?

2 Answers  


What is the difference between PS file and VSAM file?

7 Answers   IBM, Infosys, Verizon,


Categories