when i use cedf statement in cicst to debug my cics program which is related is db2, there is a error
TRANSACTION: IHH2 PROGRAM: IHH2PROG TASK: 0001450 APPLID: CICST DISPLAY: 00
STATUS: COMMAND EXECUTION COMPLETE
CALL TO RESOURCE MANAGER DSNCSQL
EXEC SQL OPEN P.AUTH=WISCOH2 , S.AUTH=
PLAN=IHH2PROG, DBRM=IHH2PROG, STMT=00509, SECT=00001
SQL COMMUNICATION AREA:
SQLCABC = 136 AT X'0F908680'
SQLCODE = -904 AT X'0F908684'
SQLERRML = 026 AT X'0F908688'
SQLERRMC = '00E7009A,100,TEMP DATABASE' AT X'0F90868A'
SQLERRP = 'DSNXISCR' AT X'0F9086D0'
SQLERRD(1-6) = +1, 000, 00000, -1, 00000, 000 AT X'0F9086D8'
SQLWARN(0-A) = '_ _ _ _ _ _ _ _ _ _ _' AT X'0F9086F0'
SQLSTATE = 57011 AT X'0F9086FB'
OFFSET:X'002CF4' LINE:UNKNOWN EIBFN=X'1802'
and the opened cursor has been rolled back(or perhaps never be opened)
so systems displayed this:
STATUS: COMMAND EXECUTION COMPLETE
CALL TO RESOURCE MANAGER DSNCSQL
EXEC SQL (NOT KNOWN) P.AUTH=WISCOH2 , S.AUTH=
PLAN=IHH2PROG, DBRM=IHH2PROG, STMT=00302, SECT=00001
SQL COMMUNICATION AREA:
SQLCABC = 136 AT X'0F908680'
SQLCODE = -501 AT X'0F908684'
SQLERRML = 000 AT X'0F908688'
SQLERRMC = '' AT X'0F90868A'
SQLERRP = 'DSNXERT' AT X'0F9086D0'
SQLERRD(1-6) = -240, 000, 00000, -1, 00000, 000 AT X'0F9086D8'
SQLWARN(0-A) = '_ _ _ _ _ _ _ _ _ _ _' AT X'0F9086F0'
SQLSTATE = 24501 AT X'0F9086FB'
OVAR 001: TYPE=DECIMAL, LEN=05.00, IND=000 AT X'0F908709'
+ DATA=X'004040'
OFFSET:X'002278' LINE:UNKNOWN EIBFN=X'1802'
how can i solve this problem? is there something wrong with the embeded statement of declare cursor in cobol like this:
EXEC SQL
DECLARE CSR-ATHSJNL SENSITIVE STATIC SCROLL CURSOR
WITH HOLD FOR
SELECT TRXCODE,AMOUNT2,AMOUNT3,WORKDATE,WORKTIME
FROM WISCOH2.ATHSJNL
WHERE DAYS(WORKDATE) >= DAYS(:H-START)
AND DAYS(WORKDATE) <= DAYS(:H-END)
AND MEDTYPE = :ATHSJNL-MEDTYPE
AND CARDNO = :ATHSJNL-CARDNO
AND ACCNO = :ATHSJNL-ACCNO
END-EXEC