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
HenryMa
Frequent Visitor

Adding Parameter to second dataset

In Power BI Report Builder, I have two Datasets (DataSet1 and DataSet2).  On my Table, I have two columns, one column comes from DataSet1 and another is an expression to do a Lookup to get a column from DataSet2.  I want to add a Parameter to DataSet2, so that I can restrict the values in the Lookup, but I get an error "The parameter <ccon>@PARAM/ccon> is not referred in the query."  Any ideas how to do this?

 

thanks!

1 ACCEPTED SOLUTION
sevenhills
Super User
Super User

Check these links and see if it helps:

https://community.fabric.microsoft.com/t5/Desktop/Report-Builder-Parameters/td-p/2250770 

https://www.mssqltips.com/sqlservertip/5865/sql-server-reporting-services-report-builder-with-dax-qu...

 

If this is not fixed, reply with the type of data source you are using.

FYI, For SQL, it may be simple steps, for DAX, little more steps.

 

View solution in original post

4 REPLIES 4
sevenhills
Super User
Super User

Check these links and see if it helps:

https://community.fabric.microsoft.com/t5/Desktop/Report-Builder-Parameters/td-p/2250770 

https://www.mssqltips.com/sqlservertip/5865/sql-server-reporting-services-report-builder-with-dax-qu...

 

If this is not fixed, reply with the type of data source you are using.

FYI, For SQL, it may be simple steps, for DAX, little more steps.

 

The first link showed me the syntax I needed to make this work. thank you!

foodd
Super User
Super User

Feedback only as I don't have a way to test.  In Power BI Report Builder, you can indeed add parameters to datasets to restrict the data based on user input. However, when using a parameter in a Lookup expression, you need to ensure that the parameter is actually used in the dataset query. The error message you encountered indicates that the parameter is defined but not referred to in the query.

HenryMa
Frequent Visitor

How do I ensure the parameter is actually used in the dataset? 

 

Sorry, let me try to re explain my situation.  I have two Datasets that I refresh on a daily basis.  I am creating a Paginated Report that pulls fields from both datasets.  Since I'm not working with a model, I can't create a relationship between the two Datasets, so I use a Lookup expression to get the fields from the second Dataset.  However, I want to allow the user to limit the data in the second Dataset, so I attempted to create the parameter in the second dataset under "Dataset Properties" -> "Parameters".  

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.