Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hola a todos - Estoy buscando orientación o ejemplos sobre un cálculo.
Sitio | Fecha | Valor real | Valor real más reciente |
Sitio A | 1-Jun | 10 | 10 |
Sitio A | 2-Jun | 10 | |
Sitio A | 3-Jun | 10 | |
Sitio A | 4-Jun | 10 | |
Sitio A | 5-Jun | 10 | |
Sitio A | 6-Jun | 200 | 200 |
Sitio A | 7-Jun | 200 | |
Sitio A | 8-Jun | 200 | |
Sitio A | 9-Jun | 200 | |
Sitio A | 10-Jun | 200 | |
Sitio B | 1-Jun | 30 | 30 |
Sitio B | 2-Jun | 30 | |
Sitio B | 3-Jun | 30 | |
Sitio B | 4-Jun | 100 | 100 |
Sitio B | 5-Jun | 100 |
Hola @luke_f ,
Puede crear una medida como se indica a continuación:
Measure =
var _curdate=MAX('Table'[Date])
var _predate=CALCULATE(MAX('Table'[Date]),FILTER(ALL('Table'),'Table'[Date]<_curdate&&NOT(ISBLANK('Table'[Actual Value]))))
var _prenum=CALCULATE(MAX('Table'[Actual Value]),FILTER(ALL('Table'),'Table'[Date]=_predate&&'Table'[Site]=MAX('Table'[Site])))
return if(ISBLANK(MAX('Table'[Actual Value])),_prenum,MAX('Table'[Actual Value]))
Saludos
Rena
Pruébalo.
Column =
VAR _RowDate = 'Table'[Date]
RETURN
CALCULATE(LASTNONBLANK('Table'[Actual Value],TRUE()),ALLEXCEPT('Table','Table'[Site]),'Table'[Date] <= _RowDate)
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
2 | |
2 | |
2 | |
2 | |
1 |