MainView for CICS: How to select CMRDETL records with Performance Reporter Language by comparing the CICS transaction's Response Time to a value contained in a variable?

Version 2
    Share This:

    This document contains official content from the BMC Software Knowledge Base. It is automatically updated when the knowledge article is modified.


    PRODUCT:

    MainView for CICS


    APPLIES TO:

    MainView for CICS



    QUESTION:

    MainView for CICS 6.4.00
    MainView for CICS 6.5.00

     I'm using the Performance Reporter Language (PRL) to produce reports on CICS transactions but I would like only to select the transactions which have a Response Time greater than a given value.

    The following syntax does not give the expected result:

    DEFINE TRESP    EDIT ZZZ9.999999
         SET TRESP = 0.5
    SELECT:
     SELECT TYPE 6E AND 6D RECORDS FROM CMRDETL
            WHERE CMRDATE = 'mm/dd/yyyy'
            IF T6ERESP  < TRESP THEN GOTO SELECT

    I've tried to change the picture of the variable on the DEFINE statement but it does not work.

    Please can you tell me how to achieve this?


    ANSWER:

     

    Legacy ID:KA409460

      

    You have several ways to achieve this:

    - the first option is to use a variable on the WHERE statement at record's selection time:

    DEFINE TRESP    EDIT ZZZ9.999999
         SET TRESP = 0.5

    SELECT:
     SELECT TYPE 6E AND 6D RECORDS FROM CMRDETL
            WHERE CMRDATE = 'mm/dd/yyyy'
              AND T6ERESP >= TRESP

    - the second option is to use a variable on the IF statement just after the record's selection time:

    DEFINE TRESP    EDIT ZZZ9.999999
         COMPUTE TRESP = 0.5

    SELECT:
     SELECT TYPE 6E AND 6D RECORDS FROM CMRDETL
            WHERE CMRDATE = 'mm/dd/yyyy'
            IF T6ERESP  < TRESP THEN GOTO SELECT

    Note: in the above case, the COMPUTE control statement is used to set the value of the variable.

      

    You can also use a specific value in place of a variable:

    - this option uses a value on the WHERE statement at record's selection time:

    SELECT:
     SELECT TYPE 6E AND 6D RECORDS FROM CMRDETL
            WHERE CMRDATE = 'mm/dd/yyyy'
              AND T6ERESP >= 0.5

    - this option uses a value on the IF statement just after the record's selection time:

    SELECT:
     SELECT TYPE 6E AND 6D RECORDS FROM CMRDETL
            WHERE CMRDATE = 'mm/dd/yyyy'
            IF T6ERESP  <  0.5 THEN GOTO SELECT

      
    Related Products:  
       
    1. MainView for CICS

     


    Article Number:

    000028185


    Article Type:

    FAQ/Procedural



      Looking for additional information?    Search BMC Support  or  Browse Knowledge Articles