0% found this document useful (0 votes)
13 views

Error Codes

Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views

Error Codes

Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 15

ILBOABNO is the user Abend handling routine.

in BATCH when user


abend occurs in application program execution
————————————

EXEC CICS ABEND ABCODE(9999) END-EXEC – user abend


handling in cics

-CICS ABEND Command


USER-ABEND:
In batch COBOL, the user ABENDS can be thrown by calling
the assembler routine ILBOABN0 using AB-CODE whereas
AB-CODE is working storage field of half word binary.

The following command is used to throw user ABENDS in


CICS.

Syntax:
EXEC CICS ABEND ABCODE(‘9999’)
The above CICS command is used to throw user ABEND
9999.

Example:
WORKING-STORAGE SECTION.
77 MSG-LEN PIC S9(4) COMP.
01 MSG-DATA.
05 MSG-DATA1 PIC X(15).
05 MSG-DATA2 PIC X(50).
:
PROCEDURE DIVISION.
:
EXEC CICS HANDLE ABEND
LABEL(ABEND-ROUTINE)
END-EXEC.
:
ABEND-ROUTINE.
MOVE ‘ABEND OCCURED.’ TO MSG-DATA1.
MOVE ‘TASK CANCELLED WITH ABCODE 9999.’ TO MSG-DATA2.
MOVE 65 TO MSG-LEN.
EXEC CICS SEND
FROM (MSG-DATA)
LENGTH(MSG-LEN)
NOHANDLE
END-EXEC.
EXEC CICS HANDLE ABEND
CANCEL
END-EXEC.
EXEC CICS ABEND
ABCODE(‘9999’)
END-EXEC.
HANDLE CONDITION and IGNORE CONDITION commands
remain in effect until program ends.

Db2 precompile pgm is DSNHPC


Compile step pgm IGYCRCTL
.LINK EDIT -IEWL
Bind and RUN IKJEFT01
CICS map assembled and link edited using pgm= ASMA90

CICS

ABEND CODES

ASRA - DATA EXCEPTION (Simillar to SOC7)

AEY9 - db2/ims not up.

AKCT -The task was cancelled due to long time waiting for an user input

What is error code 4038 in CICS?


A COBOL application running above the line is dynamically calling an assembler program that is running below the line. Whenever the call
is made, the abend U4038 occurs.15 Jun 2018
What is the Abend code U4038 in JCL?
A U4038 abend occurs when an unhandled ERROR condition is triggered within an Open PL/I program.

4038 normally indicates your Cobol program has referenced an index outside the range of the occurs within a working storage table.in cics

EIBRESP CODES - EIBRESP2 - Contains more detailed information that can


help explain why the RESP condition occurred.

HYPERLINK "https://www.mainframestechhelp.com/tutorials/cics/20-
endfile.html"https://www.mainframestechhelp.com/tutorials/cics/20-
endfile.html

After a CICS operation use


If WS-RESP = DFHRESP(NORMAL)

If WS-RESP = DFHRESP(LENGERR)

OR

If WS-RESP = EIBRESP(0),

OR

EVALUATE EIBRESP
WHEN DFHRESP(NORMAL)
DO SOMETHING
WHEN NOT DFHRESP(NORMAL)
GOTO ABEND ROUTINE
END-EVALUATE

EIBRESP Description
-------- --------------
000 x00 NORMAL
012 x0C FILENOTFOUND
013 x0D NOTFND
014 x0E DUPREC –Alternate index with
UNIQUE option
At WRITE –A record with the same key
already exists. Rewrite the record
At REWRITE,- An attempt was made to
REWRITE a record where the key already
exists. ALT.index definition is with UNIQUE
KEY. Change logic
HYPERLINK "https://www.mainframestechhelp.com/tutorials/cics/file-
write.htm"WRITE

15 – DUPKEY- Alternate index with NONUNIQUE


KEY option.
An attempt is to add a record to a file in which
the same key already exists.

Solution: - The attempt is to add a record with a


duplicate key. If required update the data in the
record, rewrite the record. Change the program
logic accordingly.

015 x0F DUPKEY


Command RESP2, Description & Solution
DELETE 140 - A record is accessed by way of an alternate index with
the NONUNIQUEKEY attribute and another alternate index record with
the same key follows.

Solution: - Verify the record key and use READ with UPDATE to delete
specific record or use generic key to delete both if the second record
is not important.READ
READNEXT
READPREV 140 - A record is accessed by way of an alternate index
with the NONUNIQUEKEY attribute and another alternate index record
with the same key follows.

Solution: - Verify the record key and use READ with UPDATE to delete
specific record or use generic key to delete both if the second record
is not important.
When it happens is while DELETE the
record, Use the logic of READ with UPDATE
option before issuing DELETE.

016 x10 INVREQ - It mostly occurs, when


the performing actions (DELETE, REWRITE
etc) are not authorised or not given in the
file definition
HYPERLINK "https://www.mainframestechhelp.com/tutorials/cics/file-
delete.htm"DELETE

20 - Delete operations are not allowed according


to the resource definition.

Solution: - Change the resource definitions if the


deletion is valid or do not perform delete if the
file definitions are correct.

- The KEYLENGTH and GENERIC options specified


for a VSAM FILE and the length value in the
KEYLENGTH option is greater than or equal to the
length of a full key.

Solution: - When a KEYLENGTH and GENERIC


options specified, it is a generic key and the length
value should be less than the length of the full key.
Change the program to modify the length value.
- ——————

019 x13 NOTOPEN


Below are the reasons for NOT-OPEN
The requested file is CLOSED and UNENABLED.

020 x14 ENDFILE


An end-of-file condition is detected
during the browse.

Solution: - File end reached during the browse and


should be handled programmatically. Modify the
program to handle the error to continue the flow.
022 x16 LENGERR
The COMMAREA length is less than 0 or
greater than the permitted length.

036 x24 MAPFAIL

How do I avoid Mapfail in CICS?


Default action: terminate the task abnormally. So if
you can educate your terminal users to NEVER use a
CLEAR key, or PA key, or hit the enter key by
accident before entering data -- then you could
prevent a MAPFAIL.
—————————————————————————————
—VSAM - File Status
Code Description
0Operation completed
successfully

10End of File encountered

22Primary duplicate Key


found
23Record not found or File
not found

35While performing OPEN


File and file is not
present

93Resources are not


available

——————
JCL ABEND
SPACE
HYPERLINK
"https://www.techagilist.com/mainframe/jc
l/space-abend-sb37-sd37-se37-
resolution/"Space ABEND – SB37, SD37,
SE37 & Resolution - Tech Agilist
https://www.techagilist.com › Blog
What are SD37, SB37, SE37 abends in jcl?
All indicate dataset out of space.
SD37 – no secondary allocation was specified.
SB37 – end of vol. and no further volumes specified.
DATACLASS=COMPRESS, ‘Z’ option to COMPRESS,
Specify the PEAK SIZE (Check for the previous RUNS and
see the peak size of the file) The PEAk size + 50% space for
PRIMARY and 20% increase in SIZE for SECONDARY, USE
the LARGE,XLARGE size of your Instalation specified values
in SPACE allocation. NM,, GDetaily, Use Dataset name type
Large: In order to accommodate huge volume
datasets Large format PS files were introduced in z/OS 1.7 .
SE37 – Max. of 16 extents already allocated.
ALL VOLUMES are FULL.Use TMSFORMAT while
allocating space so that new VOLUMES will be allocated
with the SPACE specified newly.
TMSFORMAT - Its all about tape. TMSXTEND can be used to
move the TMC ( HYPERLINK
"https://techdocs.broadcom.com/us/en/ca-mainframe-
software/performance-and-storage/ca-1-tape-management-
system/14-0/programming/data-set-requirements/tmc-tape-
management-catalog-cai-ca1-tmc-required.html"TMC - Tape
Management Catalog) to a new volume, reblock the TMC,
and extend the TMC by adding new volume ranges. So more
space will be available. How we are getting more spaces is,
the ranges of volumes can optionally be marked as inactive
(deleted) while installation time for future expansion.

————

Notes on SPACE CACULATION based on records


—-One cylinder=15 tracks and 1 track=192kb or 196608
bytes.
One CYL =2889KB OR 2.8 MB

— how many tracks in one cylinder -15 TRACKS


Its all depends upon DASD Models

———

1.What is SOC1 error?


-Due to misspelled DD name
-Read to DSN opened as OUTPUT
-called subprogram not found

2. What is SOC4 error?


Reading a file that is not open.
Invalid address referenced due to subscript error
Storage violation error

12. When is S0C5 caused?

The main reasons for the occurrence of S0C5 are-

 When an incorrect exit occurs from a platform.

 The index or subscript is damaged.


 When an unopened dataset is tried to be closed.

 When the I/O is accessed before the operation is read.

3.What is SOC7 error?


Invalid data in numeric field
---------------------

———————————————
14. Explain the terminologies- AMODE(24), AMODE(31), RMODE(24), and RMODE(ANY).

All of are the compile or link editing options.

AMODE refers to Addressing Mode. AMODE(24) represents the 24-bit addressing mode, and AMODE(31) represents the 31-bit addressing mode.

RMODE refers to Resident Mode. RMODE(24) represents the residence of a mode within the below 16 Meg line virtual storage. RMODE(ANY)
represents the residence of any level below or above the 16 Meg line.

2. Mention some popular competitors and alternatives to COBOL.

The most popular alternatives to COBOL include Java, Python, Cobalt, JavaScript, and C language.

Differentiate between Object-Oriented COBOL programming and Structured COBOL programming.

Object-Oriented COBOL programming enables writing the code naturally. Here, the objects are identified, and the procedures, as well as functions,
are written around that object.

Structured programming enables writing the code logically. It divides the functionalities into modules, and then the code is written logically.

------

DB2 - SQL ERROR CODES

-305Null values exception.


The cursor fetches
returning the null values
which was not handled
with NULL indicator.
The SELECT query
retrieving NULL values
which are not handled
with NULL indicator.
The UPDATE/INSERT
trying to insert/update
NULL values without
handling it through
NULL indicator.

-310Missing decimal values.


This will happen when
any Numeric host
variable is used to
update the column
which is having the
decimal equalent
column.
-313Mismatch between
number of host
variables & number of
columns selected.
Mismatch between the
number of host
variables & numbers of
columns selected in
SELECT query or FETCH
cursor.
-803Duplicate records.
Program tries to insert
the rows which s
already existed with the
same key.
Program tries to update
the existing row which
is equalent to the key
that is already existed
in the table.
-805Plan not found /
resource not available.
Program tries to call the
program for which the
plan got corrupted or
the plan got deleted.
-811cursor not
defined/select trying to
retrieve multiple
records.
Normal select
statement in the
program retrieving more
than one row from the
table which needs a
cursor declaration.
-818Timestamp mismatches
error.
As we discussed in the
BIND process, if the
timestamp mismatched
during the compilation,
the above error will be
thrown when calling the
particular modules
which didn’t binded
properly.

-922Authorization needed.

-911 The current transaction has been rolled back


because of a deadlock or timeout. The current unit of
work was involved in an unresolved contention for
use of an object and had to be rolled back.

MQ error codes
Completion codes
The completion code parameter (CompCode) allows
the caller to see quickly whether the call completed
successfully, completed partially, or failed. The
following is a list of completion codes, with more
detail than is given in the call descriptions:
MQCC_OK - -COMPLETION CODE IS 0
Return code – 0.The call completed fully; all output
parameters have been set. The Reason parameter
always has the value MQRC_NONE in this case.
MQCC_WARNING -COMPLETION CODE IS 2
/Return code – 2. The call completed partially. Some
output parameters might have been set in addition to
the CompCode and Reason output parameters.
The Reason parameter gives additional information
about the partial completion.
MQCC_FAILED -COMPLETION CODE IS 1
Return code – 2.
The processing of the call did not complete. The
state of the queue manager is unchanged, except
where specifically noted.
The CompCode and Reason output parameters
have been set; other parameters are unchanged,
except where noted.
The reason might be a fault in the application program, or it might be
the result of some situation external to the program, for example the
user's authority might have been revoked. The Reason parameter
gives additional information about the error.

MQRC error codes –

The unit-of-work was backed out (Reason Code 2003)

Connection was broken (Reason Code 2009

The get call timed out before receiving any messages (Reason
Code 2033

Return code= 2035 MQRC_ USER NOT_AUTHORIZED


============

You might also like