Forum Discussion
Parameter in Power BI report Builder
Thank you ABD128 for the response.
I did those steps, I believe it is mentioned in one of the links I pasted.
However, when I do the 3rd step of refrerencing the parameter in the DAX - I get below error.
The query contains the 'calendardate' parameter, which is not declared.
And I guess that is where I am stuck. All those links talk about using it as above, but still not successful at my end.
Also, someone said dont go into the query designer and just do it in the text editor of data set. I tried it too, but same error as above.
Someone said paste in design mode of query designer then hit the "@" sign on the top which is for parameter and add it. But then it does not appear in the DAX. So where did it go?
Any help is much appreciated.
Hi CeeVee33
Thank you for confirming the steps. From your description, it doesn’t seem to be a DAX syntax issue or related to Performance Analyzer. The error "The query contains the 'calendardate' parameter, which is not declared" happens during validation, showing that Report Builder doesn’t recognize the parameter at the dataset level, even if it looks correctly set up in the UI. That’s why manually adding @calendardate, using TREATAS or RSCustomDaxFilter, or switching between Query Designer and text mode doesn’t fix it the parameter isn’t bound internally.
To fix this, try rebuilding the setup: delete the dataset and any related parameters, then recreate the report parameter (calendardate as Date/Time) and add it under Dataset Properties → Parameters with the mapping =Parameters!calendardate.Value. You can check the binding with a simple query like EVALUATE ROW("Test", @calendardate). If the error still shows up, it confirms the problem is with dataset parameter binding, not the DAX logic, and recreating the dataset is needed. Your approach is correct, but the main issue is the parameter isn’t recognized internally by the dataset.
Regards,
ABD