Forum Discussion
rizwanmalik
2 years agoRegular Visitor
Input string parameter in Power BI
Hi all, I have a requirement to migrate a Tableau report to Power BI. In tableau, there is a text parameter that takes a string from end user and pass it on to a stored procedure that runs and bring...
Anonymous
2 years agoNot applicable
Hi rizwanmalik, Do you tried changing the type of Parameter, Make sure it is text type then it will accept strings. I have shared few steps below as well via which you can create the parameter.
Create a Text Parameter:
- Go to the 'Modeling' tab in Power BI Desktop.
- Click 'New Parameter', set it to 'Text', and define its properties.
Create a Parameter Table:
- Go to 'Modeling' and select 'New Table'.
- Use DAX to create a table with a single row, which will hold the parameter value.
Use the Parameter in Power Query:
- Open 'Transform Data' to access Power Query Editor.
- Create a new query to call your stored procedure, incorporating the parameter value in the SQL statement.
Bind Parameter to Report Elements:
- In the 'Report' view, add a slicer or text box linked to the parameter.
- Configure visualizations to use the parameterized query.
Publish and Configure:
- Save and publish your report to Power BI Service.
- Ensure dataset settings allow user interaction with the parameter.