Announcement

Announcement Module
Collapse
No announcement yet.

QUSRJOBI - Divide by zero

Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • QUSRJOBI - Divide by zero

    Aseem, Define variable &lgtrcv as DCL VAR(&LGTRCV) TYPE(*CHAR) LEN(4) CHGVAR VAR(%BIN(&LGTRCV)) VALUE(128) The API expects a binary value for the receiver length. Regards, Carel Teijgeler

  • #2
    QUSRJOBI - Divide by zero

    Hi Carel, I tried the change and it does not work , still same error. Also if I run the same progarm in debugger it does not give me error but otherwise it gives me error. Aseem

    Comment


    • #3
      QUSRJOBI - Divide by zero

      Aseem, Perhaps a better definition of the &APIERR parameter may give some more information. DCL VAR(&APIERR) TYPE(*CHAR) LEN(256) CHGVAR VAR(%BIN(&APIERR 1 4)) VALUE(256) IF COND(%BIN(&ERROR 5 4) > 0) THEN(DO) GOTO CMDLBL(APIERR) ENDDO APIERR: CHGVAR VAR(&MSGID) VALUE(%SST(&ERROR 9 7)) CHGVAR VAR(&MSGDTA) VALUE(%SST(&ERROR 17 64)) SNDPGMMSG MSGID(&MSGID) MSGF(*LIBL/QCPFMSG) + MSGDTA(&MSGDTA) MSGTYPE(*ESCAPE) + KEYVAR(&KEYVAR) MONMSG MSGID(CPF0000) RETURN Hope this helps. Regards, Carel Teijgeler

      Comment


      • #4
        QUSRJOBI - Divide by zero

        Hi, We have written a CL to use this API the code is given below. My problem is that it gives MCH1211 (Divide by zero) from within the API QUSRJOBI. We have 2 machines running same version of OS V5R2 but it gives error on one and no error on other. First time when we call this API we pass the reset flag as 1 and all other times as 0.We do this to calculate the elapsed time at different points in calling program. Can anybody help why I am getting this error. Aseem
        Code

        Comment


        • #5
          QUSRJOBI - Divide by zero

          Hi Carel, I get the following information MSGID is CPF9999 and SNDPGMMSG tells me following Message . . . . : Function check. MCH1211 unmonitored by QUSRJOBI at statement *N, instruction X'0641'. But this really does not help as it doesn't why I am getting this error on 1 machine but same code works fine on another machine with same release of OS but I am not sure about the PTFs applied on both machine (I presume they are not same)

          Comment

          Working...
          X