Forum Discussion

Chizzo91's avatar
Chizzo91
Regular Visitor
8 years ago

create mesure under condition

Hello,

 

I have two tables, one is the Calendar and the other one is Registro_HsTeoricas:

 

Asesor  /Cantidad de Hs/ Fecha Inicio/ Fecha Final real

Josh     /8                     /01-01-2016 /  20-08-2018

Mark   /6                      /20-12-2017 /  20-08-2018

 

this two tables don't have relationship. And in the calendar table i have created a new colummn with this mesure:

 

CALCULATE(SUMX(Registro_HsTeoricas;Registro_HsTeoricas[Cantidad de Hs]);FILTER(Registro_HsTeoricas;'Date'[Date]>=Registro_HsTeoricas[Fecha Incio ]&&'Date'[Date]<=Registro_HsTeoricas[Fecha Fin Real]))

 

When i put this on a matrix i get the total sum of hours but if i wanna see for each asesor (advisor) filtering i can't get it and i don't know how to calculate for each advisor individually.

 

I hope you can help me, thanks.

3 Replies

  • v-yulgu-msft's avatar
    v-yulgu-msft
    Microsoft Employee

    Hi Chizzo91,

     

    I am not clear about the intention of your above formula. Please show us your desired result. And provide more description about your requirement.

     

    Regards,

    Yuliana Gu

    • Chizzo91's avatar
      Chizzo91
      Regular Visitor

      Yuliana,

       

      I have already fixed it! thanks!

  • Chizzo91's avatar
    Chizzo91
    Regular Visitor

    Hello,

     

    I have two tables, one is the Calendar and the other one is Registro_HsTeoricas:

     

    Asesor  /Cantidad de Hs/ Fecha Inicio/ Fecha Final real

    Josh     /8                     /01-01-2016 /  20-08-2018

    Mark   /6                      /20-12-2017 /  20-08-2018

     

    this two tables don't have relationship. And in the calendar table i have created a new colummn with this mesure:

     

    CALCULATE(SUMX(Registro_HsTeoricas;Registro_HsTeoricas[Cantidad de Hs]);FILTER(Registro_HsTeoricas;'Date'[Date]>=Registro_HsTeoricas[Fecha Incio ]&&'Date'[Date]<=Registro_HsTeoricas[Fecha Fin Real]))

     

    When i put this on a matrix i get the total sum of hours but if i wanna see for each asesor (advisor) filtering i can't get it and i don't know how to calculate for each advisor individually.

     

    I hope you can help me, thanks.