Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Buenas tardes,
Estoy buscando una medida que me de el incremento entre fechas de un valor con una condición,
Si tengo una tabla con tres columna, quiero hacer una medida que me haga el INCREMENTO
Muchas gracias de antomena,
Un saludo.
Solved! Go to Solution.
H @SergioMar15 ,
You can try the following measure.
Measure =
VAR currentFlag = MAXA('Table'[TRUE/FALSE])
VAR currentValue = SUM('Table'[Valor])
VAR currentDate = MAX('Table'[Fecha])
VAR previousTrueDate = CALCULATE(MAX('Table'[Fecha]),FILTER(ALL('Table'),'Table'[Fecha]<currentDate && 'Table'[TRUE/FALSE]=TRUE() ))
VAR previousTrueValue = CALCULATE(SUM('Table'[Valor]),'Table'[Fecha]=previousTrueDate, ALL() )
RETURN
IF(previousTrueDate = BLANK(), 0 ,
IF(currentFlag=1,currentValue-previousTrueValue, 0 )
)
The final result is as follows. Hopefully it will meet your needs.
Please see the attached pbix for reference.
Best Regards,
Dengliang Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
H @SergioMar15 ,
You can try the following measure.
Measure =
VAR currentFlag = MAXA('Table'[TRUE/FALSE])
VAR currentValue = SUM('Table'[Valor])
VAR currentDate = MAX('Table'[Fecha])
VAR previousTrueDate = CALCULATE(MAX('Table'[Fecha]),FILTER(ALL('Table'),'Table'[Fecha]<currentDate && 'Table'[TRUE/FALSE]=TRUE() ))
VAR previousTrueValue = CALCULATE(SUM('Table'[Valor]),'Table'[Fecha]=previousTrueDate, ALL() )
RETURN
IF(previousTrueDate = BLANK(), 0 ,
IF(currentFlag=1,currentValue-previousTrueValue, 0 )
)
The final result is as follows. Hopefully it will meet your needs.
Please see the attached pbix for reference.
Best Regards,
Dengliang Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
What is the logic behind the column INCREMENTO ?
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 38 | |
| 36 | |
| 33 | |
| 33 | |
| 29 |
| User | Count |
|---|---|
| 134 | |
| 96 | |
| 78 | |
| 67 | |
| 65 |