Forum Discussion
Limit query results by filtering a column with a MAX function
Hi All,
I'm working on a report which pulls data from a database which contains about 200K rows per monthly snapshot. The report only has to contain data from the latest monthly period (ergo: the MAX or TOP 1 descending value of column "Period"). I can filter this in the report layer with DAX, but my goal is to filter it in the query editor itself, so the initial load won't have to load 200K times the amount of periods and will automatically pull new periods when the refresh hits. I've found the Table.Max and the List.Max functions, but i'm not quite sure how to use them correctly in the query editor.
Any thoughts?
Thanks in advance.
Which databse are you connecting? If you use relational database, you can add this filter in your query.
Besides, you could use the embedded filter to filter your date.
Regards,
Charlie Liao
2 Replies
- v-caliao-msft
Microsoft Employee
Which databse are you connecting? If you use relational database, you can add this filter in your query.
Besides, you could use the embedded filter to filter your date.
Regards,
Charlie Liao
- SanderBeukers
Advocate I
Thanks, i wasnt aware if this built in feature.