I was able to set return code correctly, but I still have a question regarding how MAXCC was calculated.
As per one of the post, the MAXCC is decided by return-code mod 4096.
The value of return code was 1044200508. Mod of 4096 was 3132. The MAXCC displayed was 964, which is 4096 - 3132. I checked that this is true for other values too. So I wanted to know more about MAXCC and how it is set, I tried to find some manual on same but I couldnt. Request you to please let me know which manual should i refer to. I have checked LE programming guide, easytrieve,JCL & cobol but cudnt find any information.
Btw, when I displayed the hex value for return code, I got C1C2C3C4 and 964 is nothing but last 3 nibble ie 3C4. This again is true for other values too, but since I am not sure about MAXCC, I am no sure of my calculation too. SO request you to please provide me link to manual where i can get information about MAXCC.
By MAXCC I assume you mean on the NOTIFY message you receive?
0-4095 can be expressed with 24 bits, which is your three low-order nybbles. If your results show consistenly that only the last three nybbles of the four-byte binary value which Easytrieve Plus uses then that is what Easytrieve Plus does, or what z/OS does.
To find out which is truncating, make a small COBOL program that sets the RETURN-CODE to values >= 4096.
I'm not sure how well "return code/condition code" is documented as far as what you want to know, but I'd start with the JCL Reference. Other than recognising when you have a trashed value, I'm not sure how useful your researches will be, directly, but always fun to know...
Joined: 06 Jun 2008 Posts: 8378 Location: Dubuque, Iowa, USA
I think you are looking at apples, oranges, and persimmons. X'C1C2C3C4' is ABCD -- which is not numeric and not a return code / condition code. How 1044200508 is related to ABCD is not clear.
And terminology is critical in IT, where similar terms may mean very different things. And as far as I am aware, the ONLY place MAXCC is used is IDCAMS control statements. A search of the JCL manuals will not find this term used. Hence you are not using the term correctly since you have not mentioned IDCAMS at all.
@Robert - I was just playing and trying to find out whether my calculation is consistent thats why I passed ABCD.
If we find out the 16 complement of X'C1C2C3C4' then we get the number 1044200508.If I am not wrong if the MSB contains anything greater than or equal to 8, then we need to find out the sixteen complement to get the actual number.
when I mentioned MAXCC, i was referring to the return code in notify message.
@Bill - 4095 in hex is FFF, so its 12 bits or am I missing something.