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.
Hi All,
I have two connected tables #Opens & #Clicks. "ID" is the common key or common column among the two tables and both have "dates" column. I have created a Card Visual for CTOR (Count of Clicks / Count of Opens). I also have to apply a date slicer for the visual but it doesmn't work. I am new to this. Kindly help.
Solved! Go to Solution.
Hi, @Anonymous
It’s my pleasure to answer for you.
According to your description,I think you can create a date table first,and create two relationships with the two tables,then create two measure to calculate the desired result.
Like this:
Table 2 = CALENDAR(DATE(2019,1,1),DATE(2020,12,31))
COUNT of clicks = CALCULATE(COUNTROWS('#Clicks'),ALLSELECTED('Table 2'[Date]))
COUNT of open = CALCULATE(COUNTROWS('#Open'),ALLSELECTED('Table 2'[Date]))
Here is my sample .pbix file.Hope it helps.
If it doesn’t solve your problem, please feel free to ask me.
Best Regards
Janey Guo
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @Anonymous
It’s my pleasure to answer for you.
According to your description,I think you can create a date table first,and create two relationships with the two tables,then create two measure to calculate the desired result.
Like this:
Table 2 = CALENDAR(DATE(2019,1,1),DATE(2020,12,31))
COUNT of clicks = CALCULATE(COUNTROWS('#Clicks'),ALLSELECTED('Table 2'[Date]))
COUNT of open = CALCULATE(COUNTROWS('#Open'),ALLSELECTED('Table 2'[Date]))
Here is my sample .pbix file.Hope it helps.
If it doesn’t solve your problem, please feel free to ask me.
Best Regards
Janey Guo
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous , if open and click has many to many join, They should be joined. You should create common dimesions/master table+ date table and join these two with that.
refer: https://www.sqlbi.com/articles/the-importance-of-star-schemas-in-power-bi/
https://www.seerinteractive.com/blog/join-many-many-power-bi/
And :https://www.youtube.com/watch?v=Bkf35Roman8
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 |
---|---|
107 | |
98 | |
77 | |
66 | |
53 |
User | Count |
---|---|
144 | |
104 | |
100 | |
86 | |
64 |