Forum Discussion
Amica
6 years agoFrequent Visitor
Help with a custom column
Hi, I need some help with a custom column in Power Query please. I am trying to extract data from a column that is in a data dictionary. The following code works for the first row of my data...
- 6 years ago
Hi Amica ,
Would you please try to modify your query :
#"Added Custom" = Table.AddColumn(#"Renamed Columns", "Custom", each [model.PendingMandateConfigurations] [PayingTenantId]) in #"Added Custom"
v-deddai1-msft
6 years agoCommunity Support
Amica
6 years agoFrequent Visitor
Seeing that it is in a dictionary data format, PowerBI interprets each key as a new column. That is why we want to use a specific key - provided by the LatestContfigurationId - to extract only one record and allow PowerBI to ignore the rest. The value/record associated to these keys can be seen in the screenshot above.
We are able to make this work manually by providing a hard-coded key ourselves (see earlier screenshot), but this only works for the one row. We are looking to dynamically reference this value - provided by the LatestConfigurationId - so that it works for every row (see above M code).
- v-deddai1-msft6 years agoCommunity Support
Hi Amica ,
Would you please try to modify your query :
#"Added Custom" = Table.AddColumn(#"Renamed Columns", "Custom", each [model.PendingMandateConfigurations] [PayingTenantId]) in #"Added Custom"