CICS Complete Tutorial

download CICS Complete Tutorial

of 24

Transcript of CICS Complete Tutorial

  • 7/23/2019 CICS Complete Tutorial

    1/24

    CICS Customer Information Control System

    Task The fundamental unit of work scheduled by CICS such as Read from le, write tole, read from workstation, write to workstation, initiate another task, call anotherfunction and so on.

    Transaction An entity to initiate/inoke a task for e!ecution. A transaction is " to #characters lon$.A transaction is a %iece of %rocessin$ initiated by sin$le re&uest, usually by end user at aterminal.A sin$le transaction will consist of one or more a%%lication %ro$rams that, when run, willcarry out the %rocessin$ needed.

    Program Set of instructions to achiee a task.

    LUW (Logical unit of work)tells that the %iece of work should be done eithercom%letely or not done at all.

    NON AID keys Al%habets, numbers, %unctuation etc. CICS will '(T een know if user

    %resses any '(' AI) key which means it can*t detect '(' AI) keys when %ressed.

    AID Keys Attention Identier keys are +unction keys -+" to -+# , 0nter, C10AR and-A" to -A2 keys. CICS detect only AI) keys when %ressed.After te!t is ty%ed, CICS takes the control once user %resses any AI) key.-A" 34 Alt 5 -+"

    6)T 6odied )ata Ta$+RS0T +la$ ReS0T

    ontrol Programs !

    CICS nucleus is constructed by control %ro$rams

    Terminal Control Program (TCP)is used to receie messa$es from the terminal. It alsomaintains hardware communication re&uirements.

    Task Control Program (KCP)is used to simultaneously control the e!ecution of tasks andits related %ro%erties. It also handles all issues related to 6ultitaskin$.

    Program Control Program (PCP)is used to locate and load %ro$rams for e!ecution. Ittransfers the control between two %ro$rams and at the end, it returns the control to CICS.

    File control Program (FCP)%roides an a%%lication %ro$ram with the serices like read,write, insert, u%date or delete records in a le.

    Storage Control Program (SCP)is used to allocate or de3allocate the memory in CICSre$ion.

    ontrol Ta"les !

    The control tables needs to be u%dated accordin$ly with a%%lication information for thesuccessful e!ecution of CICS a%%lication %ro$ram.

    Terminal Control Table (TCT)contains the terminal I)s connected to the current CICSre$ion. 7heneer we lo$in to CICS terminal, an entry is made in TCT.

    Program control table (PCT)contains Transaction I) and the %ro$ram associated with it.

  • 7/23/2019 CICS Complete Tutorial

    2/24

    Processing Program table (PPT)contains the %ro$ram name or ma%set name, task usecounter, main stora$e address, load library address etc. 7hen CICS receies thetransaction, corres%ondin$ %ro$ram name is %icked u% from -CT and $ets loaded.

    File Control Table (FCT)contains the information about le names, le ty%es, recordlen$th etc. All the les names used in CICS must be declared in +CT.

    #ow a transaction $rocessing is %one&

    (nce the user enters transaction I)e$., T'8" on the CICS terminal, rst corres%ondin$%ro$ram name will be checked in -CT. (nce the %ro$ram is found in -CT, it checks themain stora$e address/ 1oad library address to $et the %ro$ram loaded into the memoryfor e!ecution.

    I' system transactions

    CESN (CICS Execute SigNon) This transaction is used to si$n on into the CICS re$ion.

    CEDA (CICS Execute Defnition an Aministration) This transaction is used by CICS

    administrators to dene CICS table entries and other Admin actiities.

    CE!T (CICS Execute !aster Terminal) 9sed to in&uire and u%date the status of CICSenironments. This is also used to load a new %ro$ram, load a co%y of the old %ro$raminto CICS after chan$es to %ro$ram.

    CECI (CICS Execute Comman Inter"reter) 9sed to check the synta! of CICScommands. :ere the command $ets e!ecuted only if the synta! is correct.

    CEDF (CICS Execute Debug Facilit#) 9sed for debu$$in$ the %ro$ram ste%3by3ste%which hel%s ndin$ the errors.

    CEAC (CICS Execute Aben Coes) 9sed to nd the e!%lanation for the CICS abendcodes.

    CESF (CICS Execute Sign oF$) 9sed to si$n o; from CICS re$ion.

    (S allows e!ecution of one or more tasks concurrently and this is called ultitasking.

    If one or more concurrent tasks use the same co%y of the %ro$ram, it is called

    ultit*rea%ing.

    +,,ntrancy A re3entrant %ro$ram cannot modify by itself but can re3enter itself and

    continue %rocessin$ after an interru%tion by (S.

    -uasi +eentrancy A &uasi re3entrancy is a re3entrant %ro$ram in CICS enironmentwhich means this %ro$ram will not modify by itself and can re enter to continue%rocessin$ after an interru%tion by CICS. )urin$ interru%tion, e!ecutes other CICS tasksincludin$ tasks of same %ro$ram.

    .' (.A'I APPIN/ 'UPPO+T)

  • 7/23/2019 CICS Complete Tutorial

    3/24

    AP A sin$le screen format which can be desi$ned usin$ enerates 6A-S0T denition. 6A-S0T name is aload module name which should hae an entry in --T.

    -arameters?

    T2P,34 used to dene the ma% and the ty%e.

    6A-3 -hysical ma% is created)S0CT Symbolic ma% is created@@SS-AR6

  • 7/23/2019 CICS Complete Tutorial

    4/24

    TI(A-+E yes Resumes " bytes of stora$e s%ace in the memory to e!ecute CICScommands a$ainst the ma%.

    D1#DI 9sed to dene a 6A- within the 6a%set.

    SIF0 BRows,Columns 3 4 s%ecies the siDe of the ma% to be dis%layed to the user. Thestandard siDe is # rows G8 columns1I'0 Row number where the ma% actually startsC(196' Column number where the ma% actually startsH9STI+ s%ecies entire ma% or ma% elds are left or ri$ht ustied.

    CTR1,TI(A-+E are same as )+:6S)

    D1#D1 used to dene new eld on the ma%. 7e hae to code )+:6)+ macro foreery eld %resent on the ma%.

    -(S row, col 3 s%ecies the %osition of the eld on the ma% by s%ecifyin$ row and colJ.

    I'ITIA1 s%ecies the initial alue of the eld. Same as alue clause in cobol. i.e +1)'A60contains alue KI 1(L0 CICS*.10'>T: s%ecies the len$th of the eld.ASI- means Auto ski%.)ata cannot be entered in this eld. The cursor ski%s to ne!t eld.IC Insert Cursor s%ecies the cursor needs to be %laced on this eld when the ma% isdis%layed. If IC is s%ecied more than once, the cursor is %laced in the last eld.-R(T s%ecies to %rotect this eld from enterin$ or editin$ the data9'-R(T s%ecies to un%rotect the eld to edit or enter the data

  • 7/23/2019 CICS Complete Tutorial

    5/24

    INQSET1 DFHMSD TYPE=&SYSPARM, X

    LANG=O!OL, X

    MODE=INO"T, X

    TERM=ALL, X

    DSATTS=OLOR, X

    TRL=FREE#!, X

    STORAGE=A"TO, X

    TIOAPFX=YES

    INQMAP1 DFHMDI SI$E=%24,'(, X

    LINE=1, X

    OL"MN=1

    DFHMDF POS=%1,1(, X

    LENGTH=, X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE, X

    INITIAL=)"STINQ1)

    DFHMDF POS=%1,32(, X

    LENGTH=16, X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE, X

    INITIAL=)*./0 I*0)

    TRANSID DFHMDF POS=%1,76(, X

    LENGTH='4, X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE, X

    INITIAL=)INQ1)

  • 7/23/2019 CICS Complete Tutorial

    6/24

    DFHMDF POS=%3,'1(, X

    LENGTH=42, X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE, X

    INITIAL=)T/ *./0 *.8/09 T:/ 0/ ENTER9)

    DFHMDF POS=%5,'1(, X

    LENGTH=24, X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE, X

    INITIAL=)*./0 *.8/09 9 9 9 9)

    "STNO DFHMDF POS=%5,26(, X

    LENGTH='6, X

    ATTR!=%NORM,"NPROT(, X

    OLOR=T"RQ"OISE, X

    INITIAL=);;;;;;)

    DFHMDF POS=%5,33(, X

    LENGTH='1, X

    ATTR!=AS#IP

    DFHMDF POS=%7,'1(, X

    LENGTH=24, X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE, X

    INITIAL=)N./ < A

  • 7/23/2019 CICS Complete Tutorial

    7/24

    OLOR=T"RQ"OISE

    FNAME DFHMDF POS=%,26(, X

    LENGTH=2', X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE

    ADDR DFHMDF POS=%>,26(, X

    LENGTH=3', X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE

    ITY DFHMDF POS=%1',26(, X

    LENGTH=2', X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE

    STATE DFHMDF POS=%1',47(, X

    LENGTH='2, X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE

    $IPODE DFHMDF POS=%1',5'(, X

    LENGTH=1', X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE

    MESSAGE DFHMDF POS=%23,'1(, X

    LENGTH=7>, X

    ATTR!=%!RT,PROT(, X

    OLOR=T"RQ"OISE

    DFHMDF POS=%24,'1(, X

  • 7/23/2019 CICS Complete Tutorial

    8/24

    LENGTH=2', X

    ATTR!=%NORM,PROT(, X

    OLOR=T"RQ"OISE, X

    INITIAL=)PF3=E? PF12=/@)

    DFHMSD TYPE=FINAL

    END

    I' AP

    P*ysical a$

    -hysical ma% is a load module in the load library which contains the information abouthow the ma% should be dis%layed.

    -hysical ma% is coded with

  • 7/23/2019 CICS Complete Tutorial

    9/24

    Ski%%er eld 7hen we code the ski%%er eld after an un%rotected eld and startenterin$ the alue on the eld, once the s%ecied len$th is reached then the cursormoes to the ne!t un%rotected eld.

    '96

  • 7/23/2019 CICS Complete Tutorial

    10/24

    ',ND AP0

    This command sends out%ut data to the terminal

    0E0C CICS S0')

    6A-Pma%3nameP

    6A-S0TPma%set3nameP

    Q+R(6data3area

    Q10'>T:dataalue

    Q)ATA('1

    Q6A-('1

    QC9RS(R

    Q0RAS0/0RAS0A9-

    Q+R00

  • 7/23/2019 CICS Complete Tutorial

    11/24

    Restricted C(( 0 -IC E28.

    -R(C0)9R0 )ILISI('.

    WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW

    WS0')I'> )ATA T( SCR00' W

    WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW

    6(L0 P:011( 7(R1)PT( 7S360SSA>0

    0E0C CICS S0') T0ET

    +R(6 7S360SSA>0

    0')30E0C

    WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW

    WTAS T0R6I'AT0S 7IT:(9T A' I'T0RACTI(' +R(6 T:0 9S0RW

    WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW

    0E0C CICS R0T9R'

  • 7/23/2019 CICS Complete Tutorial

    12/24

    0')30E0C.

    98 on5ersion Programs0 Sendin$ a messa$e to the terminal and receiin$ theres%onse from user is called conersation.

    An online a%%lication allows conersation between user and a%%lication by a %airof S0') and R0C0IL0 messa$es.

    +irst system sends data to the terminal and waits for the user res%onse.

    The time re&uired for the user to res%ond to this messa$e is called thinktime which is ery hi$h.

    The user %roides necessary in%ut and %resses AI) key.

    The a%%lication %rocesses the in%ut and sends the out%ut.

    The %ro$ram loaded into the main stora$e until the task ends.

    )rawback Think time is ery hi$h for conersion %ro$rams.Pseu%ocon5ersation $rogram0

    :ere the system will not wait for user res%onse, instead terminates the transaction onceit sends data to the terminal. The transaction will be started a$ain when user %resses anyAI) key.

    After termination, the system allocates resources used by this transaction to othertransactions which makes the best utiliDation of the resources.

    OA+,A is used to %ass data between tasks. 7e declare 7S3C(66AR0A in workin$3stora$e section

    D1#OA+,Ais a s%ecial memory area allocated by CICS to eery task. This is usedto %ass data between %ro$rams either of same transaction or di;erent transactions. This

  • 7/23/2019 CICS Complete Tutorial

    13/24

    should be declared in linka$e3section under 8" leel. The len$th of both ws3commareaand dfhcommarea must be same.

    7(RI'>3ST(RA>0 S0CTI('.

    8"7S3C(66AR0A.

    8M7S3)ATA -IC E"8.

    1I'A>0 S0CTI('.

    8")+:C(66AR0A.

    8M13)ATA -IC E"8.

    +,TU+N statement0

    The two ty%es are return statements are

    ". Return statement without condition, which terminates task and transaction.

    0E0C CICS R0T9R'0')30E0C

    . Return statement with condition,

    7hen the return is issued with transaction id TR'SI) statement, the controlreturns to CICS with the ne!t transaction I).

    0E0C CICS R0T9R' TR'SI)KTRA'SI)*, QC(66AR0A7S3C(66AR0A

    0')30E0C

    D1#AIDis a CICS %roided co%ybook which contains %re3coded set of ariables used bya%%lication %ro$rams. This co%ybook can be included in the a%%lication %ro$ram by thestatement C(- )+:AI).

    Dynamically o%ifying attri"utes of a 4el%0

    To modify the attributes of a eld we must include CICS %roided co%ybook )+:ATTR inthe a%%lication %ro$ram. The attribute can be chosen from the list of ariables in thatco%ybook and moed to the symbolic ariable suX!ed with A.

    I' 1ile #an%ling

    CICS allows users to access les in

    Random orderSe&uential (rder

    +an%om access

    6ost le accesses are random in online because the transactions are not batched andsorted in any order.

    The commands used for random %rocessin$

    +,AD command reads a record from a le usin$ %rimary key.

    Synta!?

  • 7/23/2019 CICS Complete Tutorial

    14/24

    0E0C CICS R0A)

    +I10PnameP

    I'T(data3area

    RI)+1)data3area

    10'>T:data3alue

    010'>T:data3alue

    0')30E0C.

    +ile 3 name of the le which is of G characters lon$ and should be enclosed in &uotes. Thele name should hae an entry in +CTI'T( a data3area ariable into which record is to be read.RI)+1) contains key of the record that needs to read10'>T: the ma! number of characters that may be read into data3area s%ecied

    010'>T: 1en$th of the key

    0!am%le?

    I)0'TI+ICATI(' )ILISI('.

    -R(>RA63I).:011(.

    )ATA )ILISI('.

    7(RI'>3ST(RA>0 S0CTI('.

    8"7S3ST)3R0C310' -IC S#C(6-.

    8"7S3ST)30310' -IC S#C(6-.

    8"7S3ST)3R0C30 -IC 2.

    8"7S3ST)3R0C -IC E=8.

    -R(C0)9R0 )ILISI('.

    6(L0 5=8 T( 7S3ST)3R0C310'.

    6(L0 K"88* T( 7S3ST)3R0C30.

    6(L0 2 T( 7S3ST)30310'.

    0E0C CICS R0A)

    +I10 P+188"P

    I'T( 7S3ST)3R0C

    10'>T: 7S3ST)3R0C310'

    RI)+1) 7S3ST)3R0C30

    010'>T: 7S3ST)30310'

    0')30E0C.

    Read command o%tions?

    >0'0RIC is used when we doesn*t know the com%lete key alue.

  • 7/23/2019 CICS Complete Tutorial

    15/24

    9-)AT0 s%ecies the record is to be obtained for u%date or deletion. Ski%%in$ this o%tionassumes read3only.0Y9A1 s%ecies that we need the record whose key matches e!actly with the ones%ecied in RI)+1)>T0Y s%ecies that we want the rst record whose key is $reater than or e&ual to the keys%ecied

    0E0C CICS R0A)

    +I10PnameP

    I'T(data3area

    RI)+1)data3area

    10'>T:data3alue

    010'>T:data3alue

    /,N,+I

    UPDAT,

    ,-UAL

    /T,-

    0')30E0C.

    Read command e!ce%tions

    '(T(-0' le not o%en'(T+') Record not found in the dataset+I10'(T+(9') 'o le name entry in +CT

    10'>0RR 1en$th of the record doesn*t match with the s%ecied in the command'(TA9T: 'ot authoriDed to use the le)9-0 If more than one record satisfy the condition of key

    W+IT,command is used to write new records into a le

    The %arameters are same as for read e!ce%t that U)ata records will be %icked +R(6 dataarea s%ecied and writes into a le.

    0E0C CICS 7RIT0

    +I10name

    +R(6data3area

    RI)+1)data3area

    10'>T:data3alue

    010'>T:data3alue

    0')30E0C.

    +ollowin$ is the e!am%le to write a record in P+188"P le where Student3id is the %rimary

    key and a new record with "8" student id will be written in the le?

  • 7/23/2019 CICS Complete Tutorial

    16/24

    I)0'TI+ICATI(' )ILISI('.

    -R(>RA63I).:011(.

    )ATA )ILISI('.

    7(RI'>3ST(RA>0 S0CTI('.

    8"7S3ST)3R0C310' -IC S#C(6-.

    8"7S3ST)30310' -IC S#C(6-.

    8"7S3ST)3R0C30 -IC 2.

    8"7S3ST)3R0C -IC E=8.

    -R(C0)9R0 )ILISI('.

    6(L0 5=8 T( 7S3ST)3R0C310'.

    6(L0 K"8"* T( 7S3ST)3R0C30.

    6(L0 2 T( 7S3ST)30310'.

    6(L0 P"8"6ohtahim 6 Tutorials-ointPT( 7S3ST)3R0C.

    0E0C CICS 7RIT0

    +I10 P+188"P

    +R(6 7S3ST)3R0C

    10'>T: 7S3ST)3R0C310'

    RI)+1) 7S3ST)3R0C30

    010'>T: 7S3ST)30310'

    0')30E0C.

    7rite command e!ce%tions are same as read command e!ce%tions

    +,W+IT,command is used to modify e!istin$ record in the le.

  • 7/23/2019 CICS Complete Tutorial

    17/24

    8"7S3ST)3R0C310' -IC S#C(6-.

    8"7S3ST)30310' -IC S#C(6-.

    8"7S3ST)3R0C30 -IC 2.

    8"7S3ST)3R0C -IC E=8.

    -R(C0)9R0 )ILISI('.

    6(L0 5=8 T( 7S3ST)3R0C310'.

    6(L0 K"8"* T( 7S3ST)3R0C30.

    6(L0 2 T( 7S3ST)30310'.

    0E0C CICS R0A)

    +I10 P+188"P

    I'T( 7S3ST)3R0C

    10'>T: 7S3ST)3R0C310'

    RI)+1) 7S3ST)3R0C30

    010'>T: 7S3ST)30310'

    9-)AT0

    0')30E0C.

    6(L0 P"886ohtahim 6 Tutorials-ntPT( 7S3ST)3R0C.

    0E0C CICS R07RIT0

    +I10 P+188"P

    +R(6 7S3ST)3R0C

    10'>T: 7S3ST)3R0C310'

    0')30E0C.

    Rewrite command e!ce%tions

    '(T(-0', 10'>0RR, '(TA9T:

    I'LR0Y s%ecies rewrite without %rior R0A) with 9-)AT0'(S-AC0 s%ecies no enou$h s%ace in the dataset

    D,L,T,command is used to delete a record from a le.

  • 7/23/2019 CICS Complete Tutorial

    18/24

    'e:uential Access

    'TA+T.+('TA+T .rowse)tells the CICS from where to start readin$ the le.+I10 and RI)+1) are same as R0A).(nly >T0Y and 0Y9A1 are allowed.

    +ile browsin$ is strictly Read3(nly, so 9-)AT0 is not allowed.

    Synta!?

    0E0C CICS STARTT: data3alue

    RI)+1) data3alue

    0')30E0C

    +,',T.+resets the startin$ %oint of the le in the middle of the browse

    Synta!?

    0E0C CICS R0S0TT0Y

    0')30E0C.

    ,ND.+allows us to end the browse once we nish readin$ the le se&uentially

    Synta!?

  • 7/23/2019 CICS Complete Tutorial

    19/24

    0E0C CICS 0')0'30RR3-ARA.

    )IS-1A P>eneral 0rrorP.

    As %er the aboe %ro$ram, if )9-0 condition arises, then the control will be %assed toE88883)9-030RR3-ARA

    #an%le A"en%0

    7hen a %ro$ram abends abnormally, CICS searches for an actie abend e!it startin$ froma lo$ical leel of an a%%lication %ro$ram to the hi$her leels. The control is $ien to therst actie abend e!it found.

    0!am%le?

    0E0C CICS :A')10 A

  • 7/23/2019 CICS Complete Tutorial

    20/24

    R0S0T

    0')30E0C

    -ro$ram or label name is used to transfer control to %ro$ram or %ara when abend occurs.

    CA'C01 cancels %reious :A')10 C(')ITI('SR0S0T to reactie %reiously cancelled :A')10 ARA63I).:011(.

    -R(C0)9R0 )ILISI('.

    0E0C CICS A'(R0 C(')ITI(' C(')ITI('%ara0')30E0C

    0!am%le The below %ro$ram will not abend een when len$th error occurs.No*an%les%ecies no action should be taken for any e!ce%tions conditions that mayoccur while e!ecutin$ CICS commands. It can be used with Read, 7rite, )elete etc.

    Synta!?

    0E0C CICS

    %ro$ram statements

    '(:A')10

    0')30E0C.

    0!am%le

  • 7/23/2019 CICS Complete Tutorial

    21/24

    0E0C CICS R0A)

    +I10P+I10"P

    I'T(7S3+I103R0C

    RI)+1)7S3ST)I)

    '(:A')10

    0')30E0C.

    Commands used for %ro$ram control serices

    3TLcommand is used to %ass the control from one %ro$ram to another %ro$ram of thesame leel. It doesn*t e!%ect the control back similar to $oto statement.

    T: "88

    0')30E0C.

    LINKcommand is used to transfer control to another %ro$ram of lower leel.

    I)0'TI+ICATI(' )ILISI('.

    -R(>RA63I).-R(>".

    7(RI'>3ST(RA>0 S0CTI('.

    8"7S3C(66AR0A -IC E"88.-R(C0)9R0 )ILISI('.

    0E0C CICS 1I'

    -R(>RA6 P-R(>P

    C(66AR0A 7S3C(66AR0A

    10'>T: "88

    0')30E0C.

    LOAD is used to load a %ro$ram or table

  • 7/23/2019 CICS Complete Tutorial

    22/24

    0E0C CICS 1(A) -R(>RA6Kname*0')30E0C

    +,L,A',is used to release a %ro$ram or table

    0E0C CICS R010AS0 -R(>RA6Kname*0')30E0C

    +,TU+Nis used to return the control to ne!t hi$her lo$ical leel

    0E0C CICS R0T9R'

    -R(>RA6 PnameP

    C(66AR0A data3alue

    10'>T: data3alue

    0')30E0C.

    Interal Control o%erations?

    A'KTI,re&uests current date and time or timestam%. This can later be moed toworkin$3stora$e ariable in the %ro$ram.

    0E0C CICS ASTI60

    QA

  • 7/23/2019 CICS Complete Tutorial

    23/24

    A &ueue of records which are created, read and deleted by di;erent tasks or%ro$rams in the same CICS re$ion.

    A record within a TSY is identied by item number and can be read se&uentially ordirectly.

    The records in the TSY are accessible until the TSY is e!%licitly deleted.

    The TSYs may be written in main stora$e or au!iliary stora$e in )AS).

    TSYs can be accessed by %ro$rams and transactions from the same CICS re$ion.

    W+IT,- T'allows you to write records into a TSY.If no such &ueue e!ists, one will be created and writes records into it.

    TSY is identied by &ueue I) "3G bytes.

    0E0C CICS 7RIT0Y TS

    Y9090 P&ueue3nameP

    +R(6 &ueue3record

    Q10'>T: &ueue3record3len$th

    QIT06 item3number

    QR07RIT0

    Q6AI' /A9EI1IAR

    0')30E0C.

    Y9090 s%ecies the name of the TSY.+R(6 s%ecies the record to be written into the &ueue10'>T: s%ecies len$th of the record

    IT06 s%ecies the item number to be assi$ned to the recordR07RIT0 is used to u%date the e!istin$ record in the &ueue6AI'/A9EI1IAR o%tion is used to store record in 6AI'/A9EI1IARA9EI1IAR is default

    +,AD- T' allows you to read the data in TSY

    0E0C CICS R0A)Y TS

    Y9090 P&ueue3nameP

    I'T( &ueue3record

    Q10'>T: &ueue3record3len$th

    QIT06 item3number

    Q'0ET

    0')30E0C.

    '0ET s%ecies the ne!t lo$ical data item to be read

    D,L,T,- T'allows you to delete an entire TSY

    0E0C CICS )010T0Y TS

    Y9090 P&ueue3nameP

  • 7/23/2019 CICS Complete Tutorial

    24/24

    0')30E0C.

    Transient Data -ueue (TD-)is the &ueue which can be created and delete &uicly.

    The contents in the Yueue can be read only once as they $et destroyed after read is%erformed.

    Allows only se&uential access.

    TSY identied by " to # char name called destinationI) which must be re$istered in )CT)estination control table.

    Intra%artition T)Y Allows se&uential access and once the record is read, it is deletedfrom &ueue.

    0!tra%artition T)Y (nce the record is read, record is not deleted from the &ueue.

    W+IT,- TD used to write into T)Y and they are always written to a le

    0E0C CICS 7RIT0Y T)

    Y9090 P&ueue3nameP

    +R(6 &ueue3record

    Q10'>T: &ueue3record3len$th

    0')30E0C.

    +,AD- TD used to read the T)Y

    0E0C CICS R0A)Y T)

    Y9090 P&ueue3nameP

    I'T( &ueue3record

    Q10'>T: &ueue3record3len$th

    0')30E0C.

    D,L,T,- TD used to delete the T)Y

    0E0C CICS )010T0Y T)

    Y9090 P&ueue3nameP

    0')30E0C