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.
I'm using Parallelperiod to get previous value and it's working correctly for most except those that don't have value existed for certain period. For example if Company A has sales both in March and April, it will work fine. But if company A only has sales in March and the filter is set for April, March sales will show as blank.
My guess is that the function couldn't find April, so it doesn't know what's the previous period to look for.
Is there any suggestion for my struggle?
Solved! Go to Solution.
Hi @Anonymous ,
It is needed to create a Calendar table, and then create relationships between 'Details' table and 'Calendar' table.
Calendar = CALENDAR ( MIN ( Details[Report date] ), MAX ( Details[Report date] ) )
Then, create your measure like so:
Measure 2 =
CALCULATE (
SUM ( 'Details'[accrual] ),
PARALLELPERIOD ( 'Calendar'[Date], -1, MONTH )
)
BTW, .pbix file attached.
Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
It is needed to create a Calendar table, and then create relationships between 'Details' table and 'Calendar' table.
Calendar = CALENDAR ( MIN ( Details[Report date] ), MAX ( Details[Report date] ) )
Then, create your measure like so:
Measure 2 =
CALCULATE (
SUM ( 'Details'[accrual] ),
PARALLELPERIOD ( 'Calendar'[Date], -1, MONTH )
)
BTW, .pbix file attached.
Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
See if my Time Intelligence the Hard Way provides a different way of accomplishing what you are going for.
https://community.powerbi.com/t5/Quick-Measures-Gallery/Time-Intelligence-quot-The-Hard-Way-quot-TIT...
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 |
---|---|
115 | |
100 | |
88 | |
68 | |
61 |
User | Count |
---|---|
152 | |
120 | |
102 | |
87 | |
68 |