Forum Discussion
hasaneyldrm
3 years agoFrequent Visitor
how to use a compared time filter
I want to see my main values like turnover and sales with certain periods (custom) and visualize the difference between them.
I'm trying to use a compared time filter, but it resets directly when I change it slightly with values. I don't understand where I went wrong.
What i did:
1-) I created a new table
Previous Date = ALLNOBLANKROW ( 'salesorder'[createdon] )
2-) I created a relationship
3-) then i sync my values with Dax
Previous SaleQuantity =
CALCULATE (
[orderNumberMeasure],
ALL ( 'salesorder'[createdon] ),
USERELATIONSHIP ( 'salesorder'[createdon], 'Previous Date'[createdon] )
)
I can clearly see that the report is working, but when I try to pull data at different times, the data is reset.
1 Reply
- some_bih
Community Champion
Hi hasaneyldrm to see any kind of previous values just use time intelligence functions in DAX, like MTD, YTD ...
some of examples on link . Hope this help
https://www.daxpatterns.com/standard-time-related-calculations/