Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
8 years ago
Solved

The same Measure but distinct dates

Hello. I have a table like this   Código F.INI_PARTIDA F.FIN_PARTIDA   SIN FECHA 10   SIN FECHA 12   10 2019   1 12   1 2019   9 2019   10 2019   SIN FE...
  • CadgiRo's avatar
    8 years ago

    With a isolated table for months, yo can do something like this:

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

    VALOR_A_BUSCAR =

    IF (

                 HASONEVALUE( Meses[Mes] );

                 VALUES( Meses[Mes] );

                 "ERROR"

    )

     

    Columna1 =

    CALCULATE(

          COUNTROWS( Facts );

          FILTER(

                 Facts;

                 Facts[F.INI_PARTIDA]=[VALOR_A_BUSCAR]

          )

    )

     

    Columna2 =

    CALCULATE(

          COUNTROWS( Facts );

          FILTER(

                 Facts;

                 Facts[F.FIN_PARTIDA]=[VALOR_A_BUSCAR]

          )

    )

     

    tell me if it's useful