Forum Discussion
ivan_abboud
3 years agoFrequent Visitor
Dynamic calculated table depending on slicer
Greetings, Community! I am working with two tables: the first table is the store dimension table, which includes columns such as the store's opening date (representing when it was first opened) ...
- 3 years ago
Hi, ivan_abboud
You can try the following methods.
Measure = Var _table=CALCULATETABLE(VALUES('Sales Table'[Store Name]),FILTER(ALL('Sales Table'),[Date]=SELECTEDVALUE('Date'[Date]))) Var _if=IF(SELECTEDVALUE('Store Table'[Store Name]) in _table,0,1) Return IF(SELECTEDVALUE('Store Table'[Closing Date])>SELECTEDVALUE('Date'[Date])&&_if=1,1,0)Is this the result you expect?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
ivan_abboud
3 years agoFrequent Visitor
Hi v-zhangti
Thanks for the solution, it solved my issue!
however, I would like to ask you about a specific part
_if=IF(SELECTEDVALUE('Store Table'[Store Name]) in _table,0,1) I understand that the SELECTEDVALUE for the date is coming from the date slicer, which will be defined by the user, but here when we apply SELECTEDVALUE on the Store Name, how actually it is calculated? what is the context?
Thanks in advance