Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi All :),
I have a sql query that is connected to sql database server.
I have a sql code that runs on a refresh but I want I want to build a tool out of it that restricts the code to whatever order number the user is looking for information about.
I feel like this is not a thing in PowerBI but is there anyway a dax code in advanced editor can reference a textbox that is on the dashboard that a user has inputed a order number too.
Hi @shahid_tanmoy00 ,
You can connect to your data source by clicking "get data" on the power bi desktop, and then enter the sql query in the "sql statement" as shown below. You can also use a SqlDataSource control with parameterized queries and assign parameter values from predefined sources or programmatically.
Please refer to the following document for more information.
Using Parameterized Queries with the SqlDataSource (VB) | Microsoft Learn
Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
19 | |
7 | |
6 | |
5 | |
5 |
User | Count |
---|---|
25 | |
10 | |
10 | |
9 | |
6 |