1. What is primary allocation for a dataset? 数据集的Primary allocation指的是什么?
The space allocated when the dataset is first created. 数据集第一次被创建的时候所分配的空间。
2. What is the difference between primary and secondary allocations for a dataset?
数据集的between primary and secondary allocations之间有什么不同?
Secondary allocation is done when more space is required than what has already been allocated.
secondary allocations是指当系统需要更多的空间的时候,数据集被新增加空间的后的增量。
3.How many extents are possible for a sequential file ? For a VSAM file ? 数据文件和VSAM文件分别最多有多少个扩展
16 extents on a volume for a sequential file and 123 for a VSAM file. 顺序文件有一个卷上有16个扩展,而VSAM有123个
4. What does a disposition of (NEW,CATLG,DELETE) mean? 处置语句(NEW,CATLG,DELETE)是什么意思?
That this is a new dataset and needs to be allocated, to CATLG the dataset if the step is successful and to delete the dataset if the step abends.
意思是,这是一个新的数据集将要被分配,编目这个数据集假如作业步是成功的,删除这个数据集假如作业步abend了。
5. What does a disposition of (NEW,CATLG,KEEP) mean? 处置语句(NEW,CATLG,KEEP)是什么意思?
That this is a new dataset and needs to be allocated, to CATLG the dataset if the step is successful and to KEEP but not CATLG the dataset if the step abends. Thus if the step abends, the dataset would not be catalogued and we would need to supply the vol. ser the next time we refer to it.
意思是,这是一个新的数据集将要被分配,编目这个数据集假如作业步是成功的,假如这个作业步不成功那就不编目了,但是作业部正常结束后,该数据集将被继续保留在相应的卷上,然而,如果这个数据集abend了,这个数据集不应该被编目,而我们应该提供vol.ser值,在下次的引用中。
6. How do you access a file that had a disposition of KEEP? 怎么使用含有处置语句KEEP的数据集
Need to supply volume serial no. VOL=SER=xxxx. 不需要提供卷的序列号, 使用VOL=SER=xxxx
7. What does a disposition of (MOD,DELETE,DELETE) mean ? 处置语句(MOD,DELETE,DELETE)是什么意思?
The MOD will cause the dataset to be created (if it does not exist), and then the two DELETEs will cause the dataset to be deleted whether the step abends or not. This disposition is used to clear out a dataset at the beginning of a job.
MOD,这个数据集将会被创建假如不存在,两个Delete将会删除数据集无论作业步骤abend与否,这个处置语句通常是用于在作业的开始用于清理数据集
8. What is the DD statement for a output file? 如何用DD语句创建输出文件
Unless allocated earlier, will have the foll parameters: 除非之前已经创建,可以用下面的参数来实现
DISP=(NEW,CATLG,DELETE), UNIT , SPACE & DCB .
9. What do you do if you do not want to keep all the space allocated to a dataset? 假如你不想保留那些已经分配给数据集的空间
Specify the parameter RLSE ( release ) in the SPACE e.g. 使用在SPACE语句中使用RLSE ( release )参数
SPACE=(CYL,(50,50),RLSE)
10. What is DISP=(NEW,PASS,DELETE)? 处置语句(NEW,PASS,DELETE)是什么意思?
This is a new file and create it, if the step terminates normally, pass it to the subsequent steps and if step abends, delete it. This dataset will
not exist beyond the JCL. 这是一个将要被创建的文件,假如作业步正常的结束,传递给子作业步,假如步骤abend了,删除它,这个数据集将在作业步结束时删除
11. How do you create a temporary dataset? Where will you use them?
Temporary datasets can be created either by not specifying any DSNAME or by specifying the temporary file indicator as in DSN=&&TEMP. We use them to carry the output of one step to another step in the same job. The dataset will not be retained once the job completes.
12. How do you restart a proc from a particular step? 如何在特定的作业步中重新启动一个子程序?
In job card, specify RESTART=procstep.stepname where procstep = name of the jcl step that invoked the proc and stepname = name of the proc step where you want execution to start
13. How do you skip a particular step in a proc/JOB? 如何跳过一个特定的作业步?
Can use either condition codes or use the jcl control statement IF (only in ESA JCL)可以使用either 或者是作业控制语句IF
13a. A PROC has five steps. Step 3 has a condition code. How can you override/nullify this condition code?
一个子程序有五个作业步?作业步3含有条件编码,你是如果覆盖/使这个条件码无效?
Provide the override on the EXEC stmt in the JCL as follows:在EXEC语句中提供覆盖
//STEP001 EXEC procname,COND.stepname=value
All parameters on an EXEC stmt in the proc such as COND, PARM have to be overridden like this.
14. How do you override a specific DDNAME/SYSIN in PROC from a JCL? 如果在子程序中覆盖一个特定DDNAME/SYSIN
//<stepname.dd> DSN=...
15. What is NOTCAT 2 ? 什么是NOTCAT 2
This is an MVS message indicating that a duplicate catalog entry exists. E.g., if you already have a dataset with dsn = xxx.yyyy; and u try to create one with disp new,catlg, you would get this error. the program open and write would go through and at the end of the step the system would try to put it in the system catalog. at this point since an entry already exists the catlg would fail and give this message. you can fix the problem by deleting/uncataloging the first data set and going to the volume where the new dataset exists(this info is in the msglog of the job) and cataloging it.
这是一个MVS信息,它表明系统已经含有一个同样编目的数据集,例如,你已经含有一个dsn为xxx.yyyy的数据集合,但是你却希望通过处置语句DISP来编码,那么你就会遇到这样错了,系统会继续打开和写入这个数据集,最后,系统会尝试对它进行编目,就在这个时候,既然一个已经存一个同名的数据集,这会导致系统fail和抛出这个消息,要修正这个文件,你可以通过删除或者对现有的这个文件接触编码。
16. What is 'S0C7' abend? 什么是SC07 abend
Caused by invalid data in a numeric field. 数字字段中含有不合法的数据
17. What is a S0C4 error ? 什么是
Storage violation error - can be due to various reasons. e.g.: READING a file that is not open, invalid address referenced due to subscript error.
18. What are SD37, SB37, SE37 abends?
All indicate dataset out of space. SD37 - no secondary allocation was specified. SB37 - end of vol. and no further volumes specified. SE37 - Max. of 16 extents already allocated.
19. What is S322 abend ?
Indicates a time out abend. Your program has taken more CPU time than the default limit for the job class. Could indicate an infinite loop.
20. Why do you want to specify the REGION parameter in a JCL step?
To override the REGION defined at the JOB card level.REGION specifies the max region size. REGION=0K or 0M or omitting REGION
means no limit will be applied.
21. What does the TIME parameter signify ? What does TIME=1440 mean ?
TIME parameter can be used to overcome S322 abends for programs that genuinely need more CPU time. TIME=1440 means no CPU time limit is to be applied to this step.
22. What is COND=EVEN ?
Means execute this step even if any of the previous steps, terminated abnormally.
23. What is COND=ONLY ?
Means execute this step only if any of the previous steps, terminated abnormally.
24. How do you check the syntax of a JCL without running it?
TYPERUN=SCAN on the JOB card or use JSCAN.
25. What does IEBGENER do?
Used to copy one QSAM file to another. Source dataset should be described using SYSUT1 ddname. Destination dataset should be decribed using SYSUT2. IEBGENR can also do some reformatting of data by supplying control cards
via SYSIN.
26. How do you send the output of a COBOL program to a member of a PDS?
Code the DSN as pds(member) with a DISP of SHR. The disp applies to the pds and not to a specific member.
27. I have multiple jobs ( JCLs with several JOB cards ) in a member. What happens if I submit it?
Multiple jobs are submitted (as many jobs as the number of JOB cards).
28. I have a COBOL program that ACCEPTs some input data. How do you code
the JCL statment for this? ( How do you code instream data in a JCL? )
//SYSIN DD*
input data
input data
/*
29. Can you code instream data in a PROC ?
No.
30. How do you overcome this limitation ?
One way is to code SYSIN DD DUMMY in the PROC, and then override this from the JCL with instream data.
31. How do you run a COBOL batch program from a JCL? How do you run a COBOL/DB2 program?
To run a non DB2 program,
//STEP001 EXEC PGM=MYPROG
To run a DB2 program,
//STEP001 EXEC PGM=IKJEFT01
//SYSTSIN DD *
DSN SYSTEM(....)
RUN PROGRAM(MYPROG)
PLAN(.....) LIB(....) PARMS(...)
/*
32. What is STEPLIB, JOBLIB? What is it used for?
Specifies that the private library (or libraries) specified should be searched before the default system libraries in order to locate a program to be executed.STEPLIB applies only to the particular step, JOBLIB to all steps in the job.
33. What is order of searching of the libraries in a JCL?
First any private libraries as specified in the STEPLIB or JOBLIB, then the system libraries such as SYS1.LINKLIB. The system libraries are specified in the linklist.
34. What happens if both JOBLIB & STEPLIB is specified ?
JOBLIB is ignored.
35. When you specify mutiple datasets in a JOBLIB or STEPLIB, what factor determines the order?
The library with the largest block size should be the first one.
36. How to change default proclib ?
//ABCD JCLLIB ORDER=(ME.MYPROCLIB,SYS1.PROCLIB)
37. The disp in the JCL is MOD and the program opens the file in OUTPUT mode. What happens ?
The disp in the JCL is SHR and the pgm opens the file in EXTEND mode. What happens ?
Records will be written to end of file (append) when a WRITE is done in
both cases.
38. What are the valid DSORG values ?
PS - QSAM, PO - Partitioned, IS - ISAM
39. What are the differences between JES2 & JES3 ?
JES3 allocates datasets for all the steps before the job is scheduled. In
JES2, allocation of datasets required by a step are done only just before
the step executes.