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
daltontouch
Regular Visitor

Forced to use aggregate (sum, avg, etc.) rather than single data point in visuals

How do I use only the most recent data point?

I have a data source which displays a history of 'events' from an application's diagnostics. This application runs on dozens of different machines, and so there are many data points. I don't care about the history, however, only the most recent data point for each machine. I've done some massaging with my queries, and now my data table only displays the most recent row for each machine. Great - this is exactly what I want.

 

However, for nearly all the visuals I've tried to use, I'm forced to choose between different aggregates for the value that I want to use. These agregates consider the other rows that are in the original data source even though these other rows and values aren't included in my query and aren't visible in the Data view. I don't understand how to make Power BI truly ignore the rows that I don't care about. 

3 REPLIES 3
v-yuta-msft
Community Support
Community Support

Hi daltontouch, 

 

"These agregates consider the other rows that are in the original data source even though these other rows and values aren't included in my query and aren't visible in the Data view."

 

<--- Which aggregation are you using and could you share some dummy data with your measure to clarify more explicitly about your issue?

 

Regards,

Jimmy Tao

Seward12533
Solution Sage
Solution Sage

If the results are not in the query or data view that there is no way I know of that PowerBI is including them.   Can you please provide more details about your data set, model and forumla.  I would guess your measure or filter context are resulting in values different than you expect but we will need more information in order to help you. 

 

Measures that you write or are implied in the visuals by dragging column names into the visual fields require aggregate values.  If you want to use distinct value calculations you could try Calculated columns.  to get single value results in a measure, the trick is to use is to use CALCULATE with FILTERs in order to restrict the results to just a single value that you care about so MAX/MIN/AVG are all the same and it does not really matter which you use.  In your table you may be implying a more granular filter context than in your visuals so its working there. 

Anonymous
Not applicable

Hello Seward, 

 i am having simular issues. could you explain exactly how to get the calculation and filters column that you discribe.

 

thanks, 

 -Collin 

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.