JCL ⭐ Featured
👁 0

Q: What is the difference between PARM and SYSIN for passing parameters?

Answer:

PARM (EXEC statement):

  • Limited to 100 characters
  • Passed in memory to program
  • Accessed via LINKAGE SECTION
  • Good for small, simple parameters

SYSIN (DD statement):

  • No practical size limit
  • Read as a file by program
  • Can contain multiple records
  • Good for control cards, complex input
// PARM example
//STEP1 EXEC PGM=MYPROG,PARM='PARAM1,PARAM2'

// SYSIN example
//SYSIN DD *
CONTROL OPTION1
DATE=20231215
LIMIT=1000
/*
COBOL ⭐ Featured
👁 0

Q: How to use CONTINUE statement?

Answer:
CONTINUE is a no-operation placeholder. Useful in EVALUATE when certain conditions need no action: WHEN 'X' CONTINUE. In IF: IF condition CONTINUE ELSE action. Maintains structure without dummy statements. Not a GOTO target.
VSAM ⭐ Featured
👁 0

Q: What is CI and CA in VSAM?

Answer:
CI (Control Interval) is I/O unit, like block. Contains records, free space, control info. CA (Control Area) is group of CIs. CISIZE affects performance. CI split when full. CA split more expensive.
COBOL ⭐ Featured
👁 0

Q: How to use EXIT PERFORM?

Answer:
EXIT PERFORM immediately exits current PERFORM loop. EXIT PERFORM CYCLE skips to next iteration. COBOL 2002+ feature. Previously used GO TO with OUT-OF-PARAGRAPH technique. Makes loop control cleaner without extra flags.
COBOL ⭐ Featured
👁 0

Q: Explain WRITE BEFORE/AFTER ADVANCING

Answer:
ADVANCING controls line spacing for print files. WRITE rec AFTER ADVANCING 2 LINES skips 2 lines first. WRITE rec BEFORE ADVANCING PAGE starts new page after. WRITE rec AFTER PAGE goes to new page first. Controls report formatting.
COBOL ⭐ Featured
👁 0

Q: How to define FILE-CONTROL?

Answer:
SELECT file-name ASSIGN TO ddname. ORGANIZATION IS INDEXED. ACCESS MODE IS DYNAMIC. RECORD KEY IS key-field. ALTERNATE RECORD KEY IS alt-key. FILE STATUS IS ws-status. Maps COBOL file to physical dataset.
JCL ⭐ Featured
👁 0

Q: What is the difference between COND and IF/THEN/ELSE?

Answer:
COND tests return codes to skip steps (negative logic - skips IF true). IF/THEN/ELSE tests conditions to execute steps (positive logic). IF supports complex expressions, COND is simpler but confusing. IF preferred for readability. COND on JOB affects all steps; on EXEC affects that step.
JCL ⭐ Featured
👁 0

Q: Explain DCB parameter

Answer:
DCB defines Data Control Block: RECFM (F/FB/V/VB/U), LRECL (record length), BLKSIZE (block size). DCB=(RECFM=FB,LRECL=80,BLKSIZE=27920). Can inherit from existing dataset. LRECL required for new datasets. BLKSIZE=0 lets system optimize.
VSAM ⭐ Featured
👁 0

Q: What is STORAGECLASS?

Answer:
SMS STORAGECLASS for VSAM placement. STORCLAS on DEFINE. Controls performance, availability. ACS routines may assign. Modern storage management. Replaces explicit volume specifications.
JCL ⭐ Featured
👁 0

Q: How does OUTPUT statement work?

Answer:
OUTPUT defines SYSOUT processing options. //OUT1 OUTPUT CLASS=A,DEST=LOCAL,COPIES=2. Reference: //SYSOUT DD SYSOUT=*,OUTPUT=*.OUT1. Centralizes output attributes. Can specify JESDS for JES-level control. Forms, burst options available.
JCL ⭐ Featured
👁 0

Q: What is IEBGENER utility?

Answer:
IEBGENER copies sequential datasets. SYSUT1=input, SYSUT2=output, SYSIN=control. Simple copy needs only SYSUT1/SYSUT2/SYSIN DD DUMMY. Can reformat, generate, edit records with SYSIN statements. Being replaced by ICEGENER.
JCL ⭐ Featured
👁 0

Q: What is COND CODE?

Answer:
Programs return condition/return code in register 15. COND parameter tests: COND=(4,LT) skips if 4 < any prior return code. Values 0-4095. Convention: 0=success, 4=warning, 8=error, 12+=severe. Used for job flow control.
CICS ⭐ Featured
👁 0

Q: Explain CICS task and transaction

Answer:
Transaction is unit of work started by TRANSID. Task is CICS execution instance. One transaction may create multiple tasks. Task has TCA (Task Control Area). EIBTRNID has transaction ID. Concurrent tasks share resources.
JCL ⭐ Featured
👁 0

Q: Explain generation data groups

Answer:
GDG maintains versions. Base defined with IDCAMS: DEFINE GDG NAME(base) LIMIT(10) SCRATCH. Reference: base(+1) new, base(0) current, base(-1) previous. LIMIT controls kept generations. NOEMPTY/EMPTY for empty condition.
JCL ⭐ Featured
👁 0

Q: How to use //IF statement?

Answer:
//IF (condition) THEN executes following steps if true. Conditions: RC, ABEND, ABENDCC, RUN, STEP.RC. Example: //IF (STEP1.RC = 0) THEN ... //ENDIF. Can nest. ELSE available. Clearer than COND parameter.
JCL ⭐ Featured
👁 0

Q: What is JESDS parameter?

Answer:
JESDS specifies JES dataset for OUTPUT. JESDS=ALL creates JESMSGLG, JESJCL, JESYSMSG. JESDS=LOG for JESMSGLG only. On OUTPUT statement. Controls system output generation. Used for output management.
JCL ⭐ Featured
👁 0

Q: Explain RECFM options

Answer:
RECFM defines record format. F=fixed, V=variable, U=undefined. B=blocked, A=ASA control, M=machine control, S=spanned. Combinations: FB=fixed blocked, VBS=variable blocked spanned. Match program expectations.
CICS ⭐ Featured
👁 0

Q: How to do interval control?

Answer:
START with INTERVAL/AFTER for delayed execution. EXEC CICS START TRANSID(xx) INTERVAL(001000). Or AFTER HOURS(1) MINUTES(30). For scheduled background work. Data via FROM or CHANNEL.
JCL ⭐ Featured
👁 0

Q: What is SYSIN DD *?

Answer:
SYSIN DD * starts instream data. Data follows until /*. Program reads via SYSIN DD. Common for utility control statements. DD DATA,DLM=xx if data contains /*. SYSIN DD DUMMY for no input.
CICS ⭐ Featured
👁 0

Q: Explain SUSPEND command

Answer:
SUSPEND yields control to other tasks. EXEC CICS SUSPEND. Allows multitasking. Task resumes when dispatched. Use sparingly. May help long-running tasks. Usually unnecessary.
JCL ⭐ Featured
👁 0

Q: What is PATHDISP parameter?

Answer:
PATHDISP=(normal,abnormal) for USS files. Options: KEEP, DELETE. PATHDISP=(KEEP,DELETE). Used with PATH parameter. Similar to DISP for MVS datasets. Controls USS file retention.
CICS ⭐ Featured
👁 0

Q: Explain PCT

Answer:
PCT (Program Control Table) defines transactions. Now RDO TRANSACTION. Links TRANSID to initial program. Security, priority, other options. CEDA DEFINE TRANSACTION.
CICS ⭐ Featured
👁 0

Q: What is attribute byte?

Answer:
Attribute byte controls field display. In BMS: ATTRB=(PROT,BRT). Protected, unprotected. Bright, normal, dark. MDT (Modified Data Tag) for transmission. Set in map or program.
CICS ⭐ Featured
👁 0

Q: How to use CURSOR option?

Answer:
CURSOR positions cursor on SEND MAP. EXEC CICS SEND MAP CURSOR(pos). Position number from 0. Or CURSOR option in symbolic map (-1 in length field). Controls data entry flow.
CICS ⭐ Featured
👁 0

Q: Explain CICS DB2 connection

Answer:
CICS connects to DB2 via thread. EXEC SQL in CICS program. RCT (Resource Control Table) defines. Thread pool for efficiency. DB2 subsystem parameter.
VSAM ⭐ Featured
👁 0

Q: How to handle RLS (Record Level Sharing)?

Answer:
RLS allows VSAM access without exclusive control. Define with SHAREOPTIONS and LOG. Enable RLS at VSAM level. CF lock structure coordinates. Better than old batch/CICS conflicts.
CICS ⭐ Featured
👁 0

Q: What is EXEC CICS SEND CONTROL?

Answer:
SEND CONTROL sends control functions. EXEC CICS SEND CONTROL ERASE FREEKB. Clears screen, unlocks keyboard. No map or data. Prepare terminal for next operation.
COBOL
👁 0

Q: Explain PERFORM VARYING with example

Answer:
PERFORM VARYING executes a paragraph while incrementing a counter. Syntax: PERFORM para-name VARYING WS-IDX FROM 1 BY 1 UNTIL WS-IDX > 10. The counter is initialized, tested, and incremented automatically. Can have nested VARYING with AFTER clause.
COBOL
👁 0

Q: What is EVALUATE statement and when to use it?

Answer:
EVALUATE is COBOL's case/switch construct. Syntax: EVALUATE TRUE WHEN condition-1 statement WHEN OTHER default END-EVALUATE. More readable than nested IF for multiple conditions. Can evaluate multiple subjects and use THRU for ranges.
COBOL
👁 0

Q: What is GOBACK vs STOP RUN?

Answer:
STOP RUN terminates entire run unit (all programs). GOBACK returns to caller; if main program, acts like STOP RUN. Use GOBACK in subprograms to return control. STOP RUN from subprogram ends everything unexpectedly.
DB2
👁 0

Q: Explain storage group

Answer:
Storage group defines volumes for data. CREATE STOGROUP name VOLUMES(vol1, vol2). Tablespaces assigned to stogroups. DB2 manages space within. PRIQTY/SECQTY control allocation. Foundation of storage management.
DB2
👁 0

Q: What is zparm?

Answer:
ZPARM (DSNZPARMs) are DB2 installation parameters. Control system behavior, limits, defaults. DSNZPARM module loaded at startup. Changes need restart usually. Critical for performance and security tuning.
DB2
👁 0

Q: Explain thread management

Answer:
Thread is DB2 connection. Allied thread for TSO/batch. DBAT (database access thread) for DDF. Pool thread for efficient reuse. Max threads controlled by zparm. Monitor active threads.
VSAM
👁 0

Q: What is CONTROLINTERVALSIZE?

Answer:
CONTROLINTERVALSIZE sets CI size explicitly. CONTROLINTERVALSIZE(4096). Powers of 2, max 32768. Let system default usually. Larger CI better sequential, worse random. Match to workload.
VSAM
👁 0

Q: How to access VSAM via CICS?

Answer:
Define FILE in CICS FCT (File Control Table). Or RDO DEFINE FILE. EXEC CICS READ FILE. VSAM must be closed to batch when CICS owns. NSRV or LSR buffering. BROWSE for sequential.
JCL
👁 0

Q: Explain SMS-managed storage

Answer:
SMS (Storage Management Subsystem) manages dataset placement. Specify STORCLAS, MGMTCLAS, DATACLAS in DD. DATACLAS sets DCB attributes, STORCLAS controls placement, MGMTCLAS defines retention. SMS uses ACS routines for assignment.
JCL
👁 0

Q: Explain JES2 control cards

Answer:
JES2 cards start with /*. /*JOBPARM limits resources. /*ROUTE sends output. /*OUTPUT JESDS specifies JES output. /*PRIORITY sets priority. Process by JES2, not passed to job. Position after JOB card before first EXEC.
JCL
👁 0

Q: What is CNTL statement?

Answer:
CNTL groups control statements. //name CNTL establishes scope. //name ENDCNTL ends it. Used with OUTPUT or other complex statements. Provides modularity. Can be referenced by name from multiple DDs.
CICS
👁 0

Q: What is CEMT?

Answer:
CEMT inquires and sets resources. CEMT I TASK shows tasks. CEMT S FILE(name) OPEN opens file. Master terminal transaction. Operational control. I for inquire, S for set.
CICS
👁 0

Q: What is FCT?

Answer:
FCT (File Control Table) defines files. Now RDO FILE. Maps name to VSAM cluster. Status, options, recovery. CEDA DEFINE FILE creates. LSR/NSR buffering options.
JCL
👁 0

Q: What is MGMTCLAS parameter?

Answer:
MGMTCLAS assigns SMS management class. Controls migration, backup, retention. MGMTCLAS=classname. Defines data lifecycle. HSM uses management class. Installation-defined policies.
JCL
👁 0

Q: How to use MODIFY parameter?

Answer:
MODIFY references FCB image. MODIFY=(fcb,trc) on OUTPUT. FCB controls forms. TRC is table reference character. For print formatting. Installation-defined FCBs. Used with special forms.
CICS
👁 0

Q: How to set field attributes?

Answer:
Modify A field in symbolic map. DFHBMUNP=unprotected, DFHBMPRO=protected, DFHBMBRY=bright. Move to field-A before SEND. Dynamic attribute control.
CICS
👁 0

Q: What is CONVERSE?

Answer:
CONVERSE combines SEND and RECEIVE. EXEC CICS CONVERSE FROM(out) INTO(in). One command for both. Simpler for simple screens. Less control than separate commands.
DB2
👁 0

Q: Explain ORDER BY options

Answer:
ORDER BY sorts results. ORDER BY col1 ASC, col2 DESC. ASC default. NULLS FIRST/LAST controls NULL position. Ordinal: ORDER BY 1, 2 uses column positions. ORDER BY CASE for custom order. Affects performance.