Forum Discussion

DesireeMaya22's avatar
DesireeMaya22
New Member
8 years ago

Calculate Measure

Hi

I tried made a function with a filtren that you can choise in the report (a visual filter)

 

X = calculATE(countrows(Circuitos),Circuitos[MAPA DESTINO]=[Base Ajustada Origen])

 

Measure = Base Ajustada Origen, the value that it generate is "HID"

 

But it not recognize the mearsure like a text. The messeage said that i can´t used a mesure with a dinamic visual.

 

could you help me?

5 Replies

  • Hi DesireeMaya22,

     

    Not really sure if I understand wht you want to achieve but when you create the measureis it based on a column or something?

     

    To use a filter on a report like a slicer or something like that you need to use a column. The use of measure implies a context and based on that the calculation is made, that's why you can't use it in as a dinamic visual since it's a calculation not a way to filter out information on a visual.

     

    Please share some sample data and expected result.

     

    Regards,

    MFelix

    • DesireeMaya22's avatar
      DesireeMaya22
      New Member

      MFelix

       

      Thanks for your answer, the issue is that I would like to use a visual filter to calculate a measure. my dashboard refers about logistics so i have to chose a departure and then the first arrive and then the first arrive become into the departure and then you have to choise an other arrive, for this reason I take a measure to mention the first arrive to use it in the second calculation. 

      I dont think about an other way to made it, even if a try to use function "IF" it doesn´t work. 

       

      • MFelix's avatar
        MFelix
        Super User

        Hi DesireeMaya22,

         

        Can you share some data and expected result so I can help you better.

         

        Regards,

        MFelix

  • Hi,

     

    Sincce you are comparing a column to a measure, you should use the FILTER() function.

     

    =calculATE(countrows(Circuitos),FILTER(Circuitos,Circuitos[MAPA DESTINO]=[Base Ajustada Origen]))

     

    Hope this helps.