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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
anupdeval
Frequent Visitor

Reg. Report Filter implementation

Hello,

 

WE are using Report Level Filter to implement a functionality to display data based on CLient Number.

 

I am using the basic filter to achive the same.

 

Question is, for implementation of filter,

Power BI brings all the data  (e.g 10 clients) & then applies filter in UI

OR

Power BI sends the filter condition to database to filter the data

 

THanks
Anup

2 REPLIES 2
Ashish_Mathur
Super User
Super User

Hi,

 

The filter condition is sent to the database only when you specify the filter condition with a formula such as in a CALCULATE() funtion.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Anonymous
Not applicable

@Ashish_Mathur: Thank you for the reply. 

We are using direct query and we have added a "Report Level Filter" and passing the value to this report level filter using URL prameter

So, when we login to the report using this URL with parameter set for one client, will Power-BI executes the query for all clients first and then filter for the selected client on the report level? 

 

Or will it directly apply to my Where clause on the SQL it self? 

 

Let's take this example this is my DAX formula: 

VAR Min_Date = MIN ( PowerBiDistinct[PyAsOfDate] )
VAR Max_Date = MAX ( PowerBiDistinct[AsOfDate] )
VAR Result =
CALCULATE (
     [Total Incurred],
    'PowerBiDistinct'[NODays] < 180,
    PowerBiDistinct[Status (As Of)] = "CL",
    PowerBiDistinct[Close Date (As Of)] >= Min_Date,
    PowerBiDistinct[Close Date (As Of)] <= Max_Date
)

RETURN
IF(ISBLANK(Result), 0 Result)

 

So, in this case will my query send the client filter to do my Min_Date and Max_Date?

Let say Client ABC has the Min_Date = 15-Jun-2016 and Max_Date = 28-Jun-2018

And Client XYZ has the Min_Date = 10-Nov-2016 and Max_Date = 31-Aug-2018

 

When I supply Client "XYZ" as my report level filter, will my result set will be 

Min_Date = 10-Nov-2016 and Max_Date = 31-Aug-2018

OR 

Min_Date = 15-Jun-2016 and Max_Date =31-Aug-2018

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.