MQ

 View Only
  • 1.  Help with QLOAD for IBM MQ

    Posted Thu April 27, 2023 01:03 PM

    Hello ibmcommunity,

     

    I am trying to get a handle on how to code the QLOAD syntax. I running QLOAD to display messages older than 30 days.

    I am coded my PARM as such but am getting HEX format but I want to read it in a readable format. I also want to be able to point to multiple input queues using the "i" option.

    Does anyone have experience with QLOAD?

     

     

    //QLOAD  EXEC PGM=QLOAD,

    //  PARM('-m MQA1 -iqueuename -FDD:FILE -T30:0:0')

    //SYSPRINT  DD SYSOUT=*

    //SYSOUT    DD  SYSOUT=*

    //FILE DD DSN=my.data.set

    /*

     

    Thank you,

     

    Judy Ellis

    Systems Management Specialist

    Judy.Ellis@kyndrl.com

     



  • 2.  RE: Help with QLOAD for IBM MQ

    User Group Leader
    Posted Thu April 27, 2023 02:45 PM

    To view data in readable format use the -dA flag. As for multiple queues, you can use the -i multiple times in the command. For further help refer to this documentation https://www.mqgem.com/qload_downloads/QLOAD.pdf



    ------------------------------
    MADHAN DHANIKACHALAM
    ------------------------------



  • 3.  RE: Help with QLOAD for IBM MQ

    Posted Tue May 02, 2023 02:06 AM

    From IBM MQ 8.0, the qload utility, shipped in IBM MQ Supportpac MO03, has been integrated into IBM MQ as the dmpmqmsg utility.

    https://www.ibm.com/docs/en/ibm-mq/9.0?topic=reference-dmpmqmsg-queue-load-unload



    ------------------------------
    JUKKA VÄHÄTÖRMÄ
    ------------------------------



  • 4.  RE: Help with QLOAD for IBM MQ

    Posted Wed May 03, 2023 02:50 AM

    Readable depends how you are viewing the output. 

    Most QLOAD text options assume ASCII. However you need to read it in EBCDIC for sysout.

    Just convert the message to EBCDIC using the QLOAD parameter -P500    (or choose another EBCDIC code page)

    I had to work this out when coding a REXX to run QLOAD and display the output using ISPF browse. If you are interested in seeing this short REXX let me know.



    ------------------------------
    Peter T
    ------------------------------



  • 5.  RE: Help with QLOAD for IBM MQ

    Posted Mon May 08, 2023 08:10 AM

    Hi Peter T.

    Thank you, I'd like to see your REXX routine. Much appreciated.

    Thank you,

    Judy



    ------------------------------
    Judy Ellis
    ------------------------------



  • 6.  RE: Help with QLOAD for IBM MQ

    Posted Thu May 11, 2023 08:25 AM
    Edited by Peter T Thu May 11, 2023 10:59 AM

    Here's the REXX, panel to follow (n.b. change 1146 to your QM EBCDIC code page number as needed)

    /* REXX TO RUN DMPMQMSG (QLOAD) ON QUEUE and ISPF browse result */
    DMPOPTS = "-da -q -P1146 "  /* HEX and TEXT in EBCDIC */
    /* GET QMGR NAME (must be on this LPAR) and Queue name */
    ADDRESS ISPEXEC "DISPLAY PANEL(MQPAN1)"
    DO WHILE (RC=0)
       CALL RUNQLOAD
       ADDRESS ISPEXEC "DISPLAY PANEL(MQPAN1)"
    END
    EXIT 0
     
    RUNQLOAD:
    "ALLOC F(DMPMQ) SP(1 2) CYL NEW LR(100) BLK(9000) RECFM(V B) REUSE"
    /* queue browsed not consumed due to -i lower case before QNAME */
    PAR2 = "'/-m" || DMPQMGR "-i" || DMPQNAME
    PAR2 = PAR2 "-FDD:DMPMQ" DMPOPTS "'"
    /* ASIS option needed to stop folding to lower case */
    "CALL 'SYS1.SCSQLOAD(QLOAD)'" PAR2 "ASIS"
    IF RC > 4 THEN RETURN
    /* Browse output with ISPF magic */
    ADDRESS ISPEXEC "LMINIT DDNAME(DMPMQ) DATAID(DID)"
    ADDRESS ISPEXEC "BROWSE DATAID("DID")"
    "FREE F(DMPMQ)"
    RETURN



    ------------------------------
    Peter T
    ------------------------------



  • 7.  RE: Help with QLOAD for IBM MQ

    Posted Thu May 11, 2023 08:27 AM

    Panel MQPAN1

    )ATTR
      + TYPE(TEXT)  INTENS(LOW)  COLOR(BLUE)   SKIP(ON)
      # TYPE(TEXT)  INTENS(LOW)  COLOR(RED)
      % TYPE(TEXT)  INTENS(LOW)  COLOR(WHITE)  JUST(LEFT) SKIP(ON)
      ! TYPE(INPUT) INTENS(LOW)  COLOR(PINK)   CAPS(ON)
      £ TYPE(INPUT) INTENS(LOW)  COLOR(RED)    CAPS(OFF)
    )BODY
    +--------------------------+  DMPMQMSG PANEL   +---------------------
    %COMMAND ===>_ZCMD
    +
    +  This runs QLOAD (DMPMQMSG)
    +  QM (on this LPAR):!DMPQMGR+
    +  QUEUE name       :!DMPQNAME                                     +
    +  QLOAD options    :£DMPOPTS                  +
    +
    +  Messages will be browsed, NOT removed, by default, in EBCDIC
    +  All messages will be shown, so do not run on a high queue depth
    +  or add a range option to the QLOAD options such as# -r0..9
    +  Press ENTER to run QLOAD and browse the output, or END to exit
    +
    )INIT
    )PROC
       VER (&DMPQMGR,NB)
       VER (&DMPQNAME,NB)
       VER (&DMPOPTS,NB)
       VPUT (DMPQMGR DMPQNAME DMPOPTS) PROFILE
    )END




    ------------------------------
    Peter T
    ------------------------------