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! I'm very much new to Power BI and I have issues all over haha, but I would love some guidance with this problem in particular!
I have three tables:
mobile_device and violation are both related by "hostname", a varchar, the unique name of the mobile_device
Each fine has a date/time value of the moment it was given.
I have created a table visualization by adding it mobile_device hostname, and violation id, and i made it show the total amount of violations per handheld device. I then added a splicer, putting in it the violation dates. This succesfully automatically filters the amount of violations given by each machine in the table, depending on the dates used on the filter!
Here's the issue, i would like to count the amount of machines that gave said fines in between the splicer dates and display it on a card, but when i place the hostname values on it, it only shows the total amount of machines without taking the fine dates into consideration. I wish i could count the amount of rows in the table visualization and be done with it, but it's in my understanding that you can't calculate based on visualizations.
I've tried using the Filter measure but PowerBI won't detect the relationships so the measure doesn't work...
Any guidance would be apreciated!
Tables
Mobile Device Table
Violations Table
Visualization
Hi @Anonymous,
According to your descriptions, it seems like a common date range analysis requirement.
If that is the case, I'd like to suggest you take a look at the following blog 'start date', 'end date' part if it suitable to your requirement:
Regards,
Xiaoxin Sheng
Hey @Anonymous ,
so the violation-table seems to be your fact table.
Why don't you count the IDs in the fact table. The following measure should give you the result:
Distinct Hostnames = DISTINCTCOUNT( violation[hostname] )
Like this you should get the distinct amount of different hostnames based on all filters.
If you count the amount of different hostnames in the mobile_device table it always shows the total as there won't apply any other filters.
Also think to create a proper data table, that will help you a lot when analyzing with time intelligence.
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 |
---|---|
110 | |
94 | |
82 | |
66 | |
58 |
User | Count |
---|---|
151 | |
121 | |
104 | |
87 | |
67 |