Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
Solved! Go to Solution.
Hello @Emma_ - thanks for posting in the Fabric Community.
Below is one way you can get the outcome you are expecting. Please let me know if you have any questions.
In this example I am creating a table which displays the email addresses from the parameter paramTesterEmails split into separate rows (one per email), with two additonal columns populated by the parameters paramTesterRoleId and paramClientEntityId.
Parameters in Power Query:
Create a new function:
For your use case you can simply replace the parameter names with your real parameter names as well as what you'd like your columns to be named.
let
fn = ( ) =>
let
Source = Text.Split(paramTesterEmails,","),
ListToTable = Table.FromList(Source, Splitter.SplitByNothing(), {"UPN"}, null, ExtraValues.Error),
ChangeTypes = Table.TransformColumnTypes(ListToTable,{{"UPN", type text}}),
AddId = Table.AddColumn(ChangeTypes, "TesterRoleId", each paramTesterRoleId, Int64.Type),
ClientEntityId = Table.AddColumn ( AddId, "ClientEntityId", each paramClientEntityId, Int64.Type )
in
ClientEntityId
in
fn
Then invoke the function to produce the table:
If this post helps to answer your questions, please consider marking it as a solution so others can find it more quickly when faced with a similar challenge.
Proud to be a Microsoft Fabric Super User
It is really amazing, thank you so much for your quick response and a great solution !
You are very welcome!
Hii @Emma_
The selected Power Query parameter value can be exposed in the report by creating a small query that returns the parameter as a table and loading it into the model. In Power Query, create a new blank query and use M like:
= #table({"Environment"}, {{ParameterName}})
Load this query to the model and create a card, table, or measure in the report to display it. After every refresh, the table will show the currently selected parameter value (e.g., Preprod or Prod), allowing users to clearly see which data source the report was loaded from.
check the link below:-
https://learn.microsoft.com/en-us/power-query/power-query-query-parameters
Hello @Emma_ - thanks for posting in the Fabric Community.
Below is one way you can get the outcome you are expecting. Please let me know if you have any questions.
In this example I am creating a table which displays the email addresses from the parameter paramTesterEmails split into separate rows (one per email), with two additonal columns populated by the parameters paramTesterRoleId and paramClientEntityId.
Parameters in Power Query:
Create a new function:
For your use case you can simply replace the parameter names with your real parameter names as well as what you'd like your columns to be named.
let
fn = ( ) =>
let
Source = Text.Split(paramTesterEmails,","),
ListToTable = Table.FromList(Source, Splitter.SplitByNothing(), {"UPN"}, null, ExtraValues.Error),
ChangeTypes = Table.TransformColumnTypes(ListToTable,{{"UPN", type text}}),
AddId = Table.AddColumn(ChangeTypes, "TesterRoleId", each paramTesterRoleId, Int64.Type),
ClientEntityId = Table.AddColumn ( AddId, "ClientEntityId", each paramClientEntityId, Int64.Type )
in
ClientEntityId
in
fn
Then invoke the function to produce the table:
If this post helps to answer your questions, please consider marking it as a solution so others can find it more quickly when faced with a similar challenge.
Proud to be a Microsoft Fabric Super User
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 53 | |
| 35 | |
| 31 | |
| 19 | |
| 17 |
| User | Count |
|---|---|
| 74 | |
| 72 | |
| 39 | |
| 35 | |
| 23 |