Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
ianwuk
Helper III
Helper III

How to correctly count a filtered report?

Hello All.

 

I need help please with Power Bi.  It isn't correctly counting data that I have filtered.

 

So, for example, I want to count the number of software installations per month.

 

I have data that looks like this.

 

Installation Date    Number of Installs

11th July 2017         3

12th July 2017         4

13th July 2017         5

 

I want to total that so I have a total of 12 installs for July 2017 to date and I do this by counting.

 

However, if I have 345 installations since the start of the year, when I go to count this column it says 345 as the total.

 

I just want to total the date range of July, how can I get 12 as the total?

 

Many thanks.

1 ACCEPTED SOLUTION
ianwuk
Helper III
Helper III

I may have solved it.  Basically, the only reason it would incorrectly count is if my installation data has dates past July 2017 so Power Bi counts it all.  I need to see if the activation date data is only for July 2017, which is want I want, and filter out anything older and hopefully, I think, that will then get it counting correctly.

 

I will find out next week when back in the office.  Thanks for replying.

View solution in original post

5 REPLIES 5
ianwuk
Helper III
Helper III

I may have solved it.  Basically, the only reason it would incorrectly count is if my installation data has dates past July 2017 so Power Bi counts it all.  I need to see if the activation date data is only for July 2017, which is want I want, and filter out anything older and hopefully, I think, that will then get it counting correctly.

 

I will find out next week when back in the office.  Thanks for replying.

v-ljerr-msft
Employee
Employee

Hi @ianwuk,


I need help please with Power Bi.  It isn't correctly counting data that I have filtered.


How did you filter your data? Using a Slicer?


So, for example, I want to count the number of software installations per month.


Based on my understand, you should be able to add a Year-Month column to your table first, then use it as a Slicer to count the number of software installations for a specific month in this scenario. The formula below to create the Year-Month column is for your reference. Smiley Happy

YearMonth =
YEAR ( 'Table1'[Installation Date] ) & "-"
    & FORMAT ( 'Table1'[Installation Date], "MMM" )

 

Regards

Hello.

 

@v-ljerr-msft, I use a Matrix visualisation report and then I just filtered my data with data as visual level filters.  I am new to Power Bi.

 

In my data the installation date is in separate columns of year, month and day.

Silly question, but that formula you gave me, how is that entered?  I am still learning it all.  I want to have a dashboard for July, then make the same one in a new dashboard for August and so on.

 

@fhill, thank you for the screenshots.  I do not see the filter option in the top right corner, as per your screenshot, how did you do that?

 

Thanks.

Ian

fhill
Resident Rockstar
Resident Rockstar

Here some create examples of how to use Slicers.  (Filters on the Dashbaord itself.)

 

https://powerbi.microsoft.com/en-us/documentation/powerbi-service-tutorial-slicers/

 

 




Did I answer your question, or help you along the way?
Please give Kudos or Mark as a Solution!


https://www.linkedin.com/in/forrest-hill-04480730/

Proud to give back to the community!
Thank You!




fhill
Resident Rockstar
Resident Rockstar

We may need to see a sample of your data, or better understand how you are building your visuals.  Below to the left of the bar is my raw data.  To the right, I have filtered date with July total only.  Are you trying to build a DAX Measure for just July, or break things up by month?

 

FOrrest

 

 

Capture.PNG




Did I answer your question, or help you along the way?
Please give Kudos or Mark as a Solution!


https://www.linkedin.com/in/forrest-hill-04480730/

Proud to give back to the community!
Thank You!




Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.