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
hannaheb
New Member

Use DAX formula instead of time period parameters in custom SQL query

In a custom SQL query, time period parameters can be integrated, that can later be changed by the dashboard user and therefore the query runs in the background for this time period. Is there also a possibility to solve this via a DAX function? Basically it is about defining decils and assigning the data to those decils in relation to a time period.

3 REPLIES 3
hannaheb
New Member

Thank you for answering! The problem with Dynamic M Query Parameters is, that you can only change them in the "backend" so there is no option in the "frontend" for the dashboard viewer, right?

That's incorrect.  You can bind DAX columns to the parameter.

lbendlin
Super User
Super User

If your SQL Server is connected via Direct Query then you can use Dynamic M Query Parameters.

 

Dynamic M query parameters in Power BI Desktop - Power BI | Microsoft Learn

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.