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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
mp390988
Helper V
Helper V

report builder passing parameter

Hi,

 

I have a paginated report as below and I want to pass the two Parameters FromCalendarDate and ToCalendarDate to the Date field in my Rates dataset. 

mp390988_0-1754985577211.png

 

My Rates dataset is coming from the below mySQL script and you can see where I have highlighted in yellow is the name of the 2 parameters I want to pass.

mp390988_1-1754985775522.png

 

mp390988_2-1754985855882.png

 

I have formatted the value of my parameters so that it is in the format YYYY-mm-dd because when I run the mySQL directly as shown below, you can see I had to hardcode the dates in that format for it work:

mp390988_3-1754986043030.png

 

mp390988_5-1754986213122.png

 

and my query validates succesfully:

mp390988_6-1754986280060.png

 

But when I run the report, my tablix that is linked to my Rates datasouce is coming back empty even when I have set the From and To date as you can see from the snapshot below:

mp390988_7-1754986422161.png

 

You can also see I have an expression that prints what the From and To are but don't understand why mySQL script returns nothing?

Any help will be appreciated, thanks



 




1 ACCEPTED SOLUTION
v-nmadadi-msft
Community Support
Community Support

Hi @mp390988 
Thanks for reaching out to the Microsoft fabric community forum.


Please verify weather the Data type for the parameter is correct

vnmadadimsft_0-1755017174233.png

 



To do that, you could right click on parameter and then on parameter properties

vnmadadimsft_1-1755017174234.png

 



Additionally, test the query in MySQL with parameter values, copy your dataset query into MySQL Workbench, then replace @FromCalendarDate and @ToCalendarDate with the exact values captured from the report’s text box output. Run the query to confirm it returns rows; if it doesn’t, check for possible issues such as incorrect date formatting, missing single quotes around date values, or mismatches caused by any SQL command.

I hope this information helps. Please do let us know if you have any further queries.
Thank you

View solution in original post

5 REPLIES 5
v-nmadadi-msft
Community Support
Community Support

Hi @mp390988 

As we haven’t heard back from you, we wanted to kindly follow up to check if the suggestions  provided by the community members for the issue worked. Please feel free to contact us if you have any further questions.

 

Thanks and regards

v-nmadadi-msft
Community Support
Community Support

Hi @mp390988 

May I check if this issue has been resolved? If not, Please feel free to contact us if you have any further questions.


Thank you

v-nmadadi-msft
Community Support
Community Support

Hi @mp390988 ,

I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions.


Thank you.

v-nmadadi-msft
Community Support
Community Support

Hi @mp390988 
Thanks for reaching out to the Microsoft fabric community forum.


Please verify weather the Data type for the parameter is correct

vnmadadimsft_0-1755017174233.png

 



To do that, you could right click on parameter and then on parameter properties

vnmadadimsft_1-1755017174234.png

 



Additionally, test the query in MySQL with parameter values, copy your dataset query into MySQL Workbench, then replace @FromCalendarDate and @ToCalendarDate with the exact values captured from the report’s text box output. Run the query to confirm it returns rows; if it doesn’t, check for possible issues such as incorrect date formatting, missing single quotes around date values, or mismatches caused by any SQL command.

I hope this information helps. Please do let us know if you have any further queries.
Thank you

MohamedFowzan1
Solution Supplier
Solution Supplier

Hi @mp390988 

The approach used seems correct.

 

Steps:

  • Set Correct Data Type – Use the Date/Time type for report parameters instead of text.
  • Format Dates for MySQL – Map parameters in the dataset with expressions like=Format(Parameters!FromCalendarDate.Value, "yyyy-MM-dd")
    to match MySQL’s expected format.
  • Check Query & Parameter Mapping – Ensure parameter names match in the query and dataset mapping, and use proper syntax (e.g., BETWEEN @FromCalendarDate AND @ToCalendarDate).
  • Debug – Display formatted parameter values in the report to verify correctness before passing them to the query.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.