Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

filtering in measures

Hi everyone, I have created a measure calle NPT Days. When two filters appllied in the report mode (DTWO and WOW) it should represent the new parameter called WOW Days. The issue is that I need to display both of them in a pie chart. So I guess the question is how to display two measures one of which is derived from the first by applying two filters? Should I create a column in the Query editor and apply two filters in the formula?

 

  • Anonymous's avatar
    Anonymous
    6 years ago

    Hi Anonymous ,

    Could you please check if the below screen shot is what you want? If yes, you can create a measure for your second paramater as below:

    NPT Days for specific codes = 
    CALCULATE (
        SUM ( 'DM_OPER_EQUIP_FAIL'[npt_net_time] ),
        FILTER (
            'DM_OPER_EQUIP_FAIL',
            'DM_OPER_EQUIP_FAIL'[npt_cause_code] = "DTWO"
                && 'DM_OPER_EQUIP_FAIL'[npt_desc_code] = "WOW"
        )
    ) / 24

    Best Regards

    Rena

4 Replies

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi amitchandak. So I have a column called npt_net_time. I need to display two parameters in a pie chart - the first parameter is the measure I show above (sum of all npt_net_time). The second parameter is basically the same formula, but I need to add two filters to it (those two filters in the picture DTWO and WOW that come from other columns in the same table).

      • Anonymous's avatar
        Anonymous
        Not applicable

        Hi Anonymous ,

        Could you please check if the below screen shot is what you want? If yes, you can create a measure for your second paramater as below:

        NPT Days for specific codes = 
        CALCULATE (
            SUM ( 'DM_OPER_EQUIP_FAIL'[npt_net_time] ),
            FILTER (
                'DM_OPER_EQUIP_FAIL',
                'DM_OPER_EQUIP_FAIL'[npt_cause_code] = "DTWO"
                    && 'DM_OPER_EQUIP_FAIL'[npt_desc_code] = "WOW"
            )
        ) / 24

        Best Regards

        Rena