Wednesday, 28 January 2015

VSAM Part5 Latest Interview Questions and Answers

41. Under IDCAMS, multiple functions can be executed, each of which returns a condition code. What will be the condition code returned to the operating system?
The maximum condition code generated is returned as the condition code of the IDCAMS step.

42. Would you specify FREESPACE CE for an ESDS?
No. Because you cannot insert records in an ESDS, also when you rewrite a record, it must be of the same length. Thus putting any value for FREESPACE does not make any sense.

43. What is the meaning of each of the values in SHAREOPTS (2 3)?
Value of 2 for cross region means that the file can be processed simultaneously by multiple users provided only one of them is an updater. Value of 3 for cross system means that any number of jobs can process the file for input or output (VSAM does nothing to ensure integrity).

44. How do you define an ALTINDX? How do you use ALTINDXs in batch, CICS programs?
DEFINE ALTERNATEINDEX. Impartant parameters are RELATE where you specify the base cluster name, KEYS, RECORDSIZE, SHAREOPTION, UNIQUEKEY (or NONUNIQUEKEY), DATA (DS NAME for the data component), INDEX(DS name for the index component). Then DEFINE PATH. Important paramters are NAME (DS name for the path). PATHENTRY (DS name of the alternate index name). UPDATE (or NOUPDATE) which specifies whether an ALT index is updated when a update to the vase cluster takes place. Then BLDINDEX. Paramters are INDATASET (DS name of base cluster), OUTDATASET (DS name of AIX).

45. Name some common VSAM error conditions and codes?
They are end of file (10), duplicate key (22), record not found (23), VSAM logic error (90), open problem (92) and space problem (93).

46. What is a VSAM slot?
A relative record dataset (RRDS) consists of a specified number of areas called slots. Each slot is identified by a relative record number (RRN) which indicates its relative position in the file.

47. There are at least seven IDCAMS commands name and explain each of them?
ALTER modifies information for a catalog, alternate index, cluster or path. BLDINDEX builds the alternate index, of course. DEFINE is used for ALTERNATEINDEX, CLUSTER or PATH. DELETE removes the catalog entry for a catalog, cluster, alternate index or path. LISTCAT lists information about the dataset. PRINT prints the dataset contents. REPRO copies records from one file to another.

48. What is the significance of the SHAREOPTIONS parameter?
It specifies how the file may be shared between jobs and between batch and CICS environments.

49. What is File Status in VSAM?
The File STATUS clause of the FILE-CONTROL paragraph allows for each file to be associated with a file status key (i.e., the 2-character data item specified in the FILE STATUS clause). If the FILE STATUS clause is specified for a given file, a value indicating the status of each I/O operation against that file is placed in the accociated file status key. This value is stored in the file status key as soon as the I/O operation is completed (and before execution of any EXCEPTION/ERROR declarative or INVALIDKEY/AT END phrase associated with the I/O request).
Note: This element may behave differently when the CMPR2 compiler option is used. The file status key is divided into two status keys: the first character is known as file status key1; the second character is file status key 2.

50. If you wish to use the REWRITE command haw must the VSAM file be opened?
It must be opened as I/O.

Part1  Part2  Part3  Part4  Part5  Part6  Part7

No comments:

Post a Comment