View previous topic :: View next topic
|
Author |
Message |
Sangeetha Chelliah
New User
Joined: 03 Oct 2008 Posts: 9 Location: chennai
|
|
|
|
Hi,
When I am debugging the below code in XPED, i m getting AEIV abend. Please help me to resolve this.
*EXEC CICS WRITE DATASET(SEGNAME-DBENQTBL)
* FROM(DBENQTBL-SEG)
* RIDFLD(DBENQTBL-VSAM-KEY)
* END-EXEC.
Move length of DBENQTBL-SEG to dfhb0020
Call 'DFHEI1' using by content x'0604f0004628004400' by
reference SEGNAME-DBENQTBL by reference DBENQTBL-SEG by
reference dfhb0020 by reference DBENQTBL-VSAM-KEY end-call. --In this place i m getting AEIV abend. |
|
Back to top |
|
|
CICS Guy
Senior Member
Joined: 18 Jul 2007 Posts: 2146 Location: At my coffee table
|
|
Back to top |
|
|
Marso
REXX Moderator
Joined: 13 Mar 2006 Posts: 1353 Location: Israel
|
|
|
|
Abend AEIV in a WRITE DATASET means a LENGERR occurred.
Check the RESP2 value:
12: The length specified for the write operation exceeds the maximum record size; the record is truncated.
10: LENGTH is omitted for a WRITE to a file with variable-length records or to a BDAM file with undefined format records.
14: An incorrect length is specified for a write operation involving fixed-length records.
Check everything that has to do with the record length. |
|
Back to top |
|
|
Marso
REXX Moderator
Joined: 13 Mar 2006 Posts: 1353 Location: Israel
|
|
|
|
If RESP2 is 14, I would do a LISTCAT on the file to get the actual LRECL, and check if the record definition (DBENQTBL-SEG) in the cobol program has the same size. |
|
Back to top |
|
|
Marso
REXX Moderator
Joined: 13 Mar 2006 Posts: 1353 Location: Israel
|
|
|
|
Quote: |
*EXEC CICS WRITE DATASET(SEGNAME-DBENQTBL)
* FROM(DBENQTBL-SEG)
* RIDFLD(DBENQTBL-VSAM-KEY)
* END-EXEC.
Move length of DBENQTBL-SEG to dfhb0020
Call 'DFHEI1' using by content x'0604f0004628004400' by
reference SEGNAME-DBENQTBL by reference DBENQTBL-SEG by
reference dfhb0020 by reference DBENQTBL-VSAM-KEY end-call.
While executing this statement for the first time, I did not face any problem. When the control is coming here for the second time, I m getting AEIV abend.
I have checked the RESP2 value as suggested by you. The value for this is 14.
The layout for DBENQTBL-SEG and SEGNAME-DBENQTBL is same. Please find the below for more details.
05 SEGMENT-NAME-TABLE.
10 FILLER PIC X(8) VALUE 'SEGNAMES'.
10 SEGNAME-DBENQTBL PIC X(8) VALUE 'DBENQTBL'.
01 DBENQTBL-SEG.(| COPY DBENQTBL)
05 DBENQTBL-DATA-DEF.
10 DBENQTBL-VSAM-KEY.
15 DBENQTBL-DBID PIC X(8).
15 DBENQTBL-RKEY PIC X(20).
10 DBENQTBL-STAT PIC X(2).
10 DBENQTBL-DATE PIC 9(7) COMP-3.
10 DBENQTBL-TIME PIC 9(7) COMP-3.
10 DBENQTBL-TRAN PIC X(4).
10 DBENQTBL-PROG PIC X(8).
10 DBENQTBL-TERM PIC X(4).
So from above, the length is same for SEGNAME-DBENQTBL and DBENQTBL-SEG. So still i dont know how to solve this error? Can you suggest me to resolve this error? |
Please do not use private messages to post questions.
Maybe somebody else could have answered your question two days ago...
AEIV means LENGERR, resp2 of 14 means "An incorrect length is specified for a write operation involving fixed-length records."
1. Make sure you have a level 01 after the COPY DBENQTBL. If not, the "length of DBENQTBL-SEG" will be incorrectly calculated by the program.
2. Check (with CEMT) which file is allocated to DBENQTBL in this specific CICS.
3. Using LISTCAT, collect the actual file format (check values: KEYLEN, RKP, AVGLRECL and MAXLRECL).
4. According to program, KEYLEN=28, RKP=0, AVGLRECL and MAXLRECL both =54.
5. Are these values correct ? |
|
Back to top |
|
|
|