Forum Discussion
How to create a parameter in power bi desktop
Hello Praveen9898
Here are the steps to create parameters,
Select Data > Get Data > Other Sources > Launch Power Query Editor.
In the Power Query Editor, select Home > Manage Parameters > New Parameters.
In the Manage Parameter dialog box, select New.
Set the following as needed:
Name
This should reflect the parameter's function, but keep it as short as possible.
Description
This can contain any details that will help people correctly use the parameter.
Required
Do one of the following:
Any Value You can enter any value of any data type in the parameter query.
List of Values You can limit the values to a specific list by entering them in the small grid. You must also select a Default Value and a Current Value below.
Query Select a list query, which resembles a List structured column separated by commas and enclosed in braces.
For example, an Issues status field could have three values: {"New", "Ongoing", "Closed"}. You must create the list query beforehand by opening the Advanced Editor (select Home > Advanced Editor), removing the code template, entering the list of values in the query list format, and then selecting Done.
Once you finish creating the parameter, the list query is displayed in your parameter values.Type
This specifies the data type of the parameter.
Suggested Values
If desired, add a list of values or specify a query to provide suggestions for input.
Default Value
This only appears if Suggested Values is set to List of values, and specifies which list item is the default. In this case, you must choose a default.
Current Value
Depending on where you use the parameter, if this is blank the query might return no results. If Required is selected, Current Value cannot be empty.
To create the parameter, select OK.
You can also visit below for more details -