CICS program failed in writing/rewrting record in KSDS file



Support for CICS/ESA, CICS/TS & Transaction Gateway, CICS Configuration Manager and CICS Performance Analyzer

Re: CICS program failed in writing/rewrting record in KSDS f

Postby jcsraghavan » Fri Nov 04, 2011 12:52 am

Hi Robert,

I found one more thing hope this will explain you my problem and helps me in solving my issue

the record structure of the file where i am rewriting is

SET 1 OF 1 FILE-KEY-PN GBL = N
---- FIELD LEVEL/NAME ------- -FORMAT- RO ----+----1----+----2----+----3----+--
******************************* TOP OF DATA ***********************************
5 FILE-KEY-PN 10/GRP
10 DISTRIBUTION-CENTER-PN 2/NUM
10 WAREHOUSE-PN 2/NUM
10 WORKUNIT-PN 6/NUM
5 NDX1-KEY-PN 12/GRP
10 DISTRIBUTION-CENTER-PN-NDX1
2/NUM
10 WAREHOUSE-PN-NDX1 2/NUM
10 LOCATION-ID-PN-NDX1 8/AN
5 PRODUCT-ID-PN 7/NUM
5 AUDITED-FLAG-PN 1/AN
5 PALLET-QUANTITY-PN 4/NUM
5 FILLER 30/AN
***************************** BOTTOM OF DATA **********************************

where LOCATION-ID-PN-NDX1 is the part of alternate index key.
Before rewriting the record in the PNfile i am moving the value from MOVE TO-SLOT-LW TO LOCATION-ID-PN-NDX1.

the value moving is K34410A1 to the LOCATION-ID-PN-NDX1.
I can see that there more records present the PNfile having LOCATION-ID-PN-NDX1 = K34410A1

please check below

0206295325 0206K34410A14776114N0009
- - - - - - - - - - - - - - - - - - - - - - - - - 334401 RECORD(S) NOT SELECTED
0206688367 0206K34410A12212694N9040
0206688368 0206K34410A12212694N2050
- - - - - - - - - - - - - - - - - - - - - - - - - - - 62 RECORD(S) NOT SELECTED
0206688431 0206K34410A12212694N2026
- - - - - - - - - - - - - - - - - - - - - - - - - - 486 RECORD(S) NOT SELECTED
0206688953 0206K34410A12212694N2925
0206688954 0206K34410A12212694N3180
0206688955 0206K34410A12212694N3932
0206688956 0206K34410A12212694N5521
0206688957 0206K34410A12212694N5716
0206688958 0206K34410A12212694N5920
0206688959 0206K34410A12212694N5956
- Å¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢Õ ED
0 … FA223- Records read = 840376, selected = 50, error records skipped = 0 …
- Ä¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢Ô ED
0206688963 0206K34410A12212694N6451

so i try to write the record by changing the value other than K34410A1 and it had written successfully.

COMMAND ===> SCROLL ===> CSR
MODULE: ******************** Update completed *********************
VALID COMMANDS: READ DELETE WRITE REWRITE NEXT PREV CLOSE
ACCESS METHOD: VSAM TYPE: KSDS
FILENAME: PNFL02 RECLN: 00064 MAX RECLN: 00064
DEC-OFFSET: 000000 ADD-OFFSET: ______ RECFM: F KEYLN: 00010 RKP: 00000
KEY FIELD: ----+---10
0206689572
FFFFFFFFFF
0206689572
----+---10----+---20----+---30----+---40----+---50----+---60--64
02066895720206K34410A02212694N8752..............................
FFFFFFFFFFFFFFDFFFFFCFFFFFFFFDFFFF000000000000000000000000000000
0206689572020623441010221269458752000000000000000000000000000000
----+---10----+---20----+---30----+---40----+---50----+---60--64

Hope this information helps you in helping me
jcsraghavan
 
Posts: 6
Joined: Wed Nov 02, 2011 7:09 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Re: CICS program failed in writing/rewrting record in KSDS f

 

Re: CICS program failed in writing/rewrting record in KSDS f

Postby Robert Sample » Fri Nov 04, 2011 5:11 pm

At this point, I don't know what you think I -- or anybody else on this forum -- can do about your problem. The system is telling you that your REWRITE is failing. To find out why, someone has to do the work of tracing through the program execution to see what is happening. Since you have the source code, and you have the load module, and you have the CICS region, and you have the debugging tool, I strongly suspect the person needing to do that work will be ... YOU. You can use CEDF, or you can use Xpediter since it is installed at your site, or you could even add DISPLAY (or CMSG writes) at the start of each paragraph to trace the logic -- but you need to start doing something.

An ILLOGIC request could be your program not doing a READ UPDATE before doing the REWRITE, it could be your program changing the key value after the READ UPDATE but before the REWRITE, it could be something else such as falling through a PERFORM and executing code unexpectedly another time. In any case, you need to stop reading this forum and start doing some code review, code debugging, and resolve the problem. We cannot resolve it just by telling you things; at some point you're going to have to make the code changes yourself (once you have figured out what you need to change).
Robert Sample
Global moderator
 
Posts: 3126
Joined: Sat Dec 19, 2009 8:32 pm
Location: Bellevue, Iowa
Has thanked: 1 time
Been thanked: 185 times

Previous

Return to CICS

 


  • Related topics
    Replies
    Views
    Last post