Page 1 of 1

NOTFND condition?

PostPosted: Wed May 04, 2011 8:03 pm
by Balr14
My CICS is kind of fuzzy. I'm getting a NOTFND condition on a CICS read and I can't figure out why. The value of the RIDFLD is zeros, so any value should satify GTEQ. Can anyone offer suggestions?

EXEC CICS READ FILE ('CMTKSDS1')
INTO (W-ITEM-AREA)
LENGTH (W-ITEM-SIZE)
RIDFLD (W-ITEM-KEY)
KEYLENGTH (W-KEY-SIZE)
GTEQ
END-EXEC.

Re: NOTFND condition?

PostPosted: Wed May 04, 2011 8:16 pm
by Robert Sample
I suggest running CEDF to look at the values being used by CICS. I'd also double-check the length variables to be appropriately defined. And your statement
The value of the RIDFLD is zeros, so any value should satify GTEQ.
is meaningless -- if you meant X'F0' by "zeroes" then there are many, many values possibly less than x'F0' -- and quite possibly no values greater than that in the file (which could cause the NOTFND). If you meant binary zeroes (AKA LOW-VALUES) then you should have so stated. Using CEDF will help clarify what CICS is seeing in the RIDFLD.

Basically, CICS is telling you it didn't find a record with the data you provided in the file -- the reason why usually turns out to be something you didn't do (or did incorrectly).

Re: NOTFND condition?

PostPosted: Wed May 04, 2011 8:38 pm
by Balr14
I did use EDF and plugged in X'F0F0F0F0F0' and x'0000000000' as key values, with the same results. I verified the key size with CEDA and I did a file install, just to be sure. I wish I knew of a way to look at the file content in CICS, to see what it thinks is there.

Re: NOTFND condition?

PostPosted: Wed May 04, 2011 8:44 pm
by Robert Sample
CECI READ FILE
uses the Command Interface to directly execute CICS commands. You can read into a variable, look at the data returned (in hex or display), and so forth.

Re: NOTFND condition?

PostPosted: Wed May 04, 2011 8:49 pm
by Balr14
Cool. I will give that a try. Thanks.

Re: NOTFND condition?

PostPosted: Wed May 04, 2011 10:31 pm
by Balr14
Well, this is interesting. CECI read says NOTFND, too. I'm sure there is something obvious I'm overlooking, but I have no idea what it is. Would it matter if the file was populated after starting CICS?

Re: NOTFND condition?

PostPosted: Wed May 04, 2011 11:01 pm
by Robert Sample
Would it matter if the file was populated after starting CICS?
Possibly -- was the file empty (i.e., never had a record written to it) when CICS opened it (a good way to have various issues if it happens)? If the file was loaded (from batch, for example) while CICS had the file open, you might need to close and reopen the file to get CICS up to date. There are a lot of possible factors (is the file in an LSR pool? how busy is the LSR pool? when, exactly, was the data loaded? when, exactly, was the file opened to CICS? was a batch enqueue / dequeue method used while updating? what are the file's SHAREOPTIONS? etc etc etc) to consider.

On the bright side, at least CECI is confirming the program status for the file. Why the file isn't showing data is another problem, of course.