Forum Discussion
pbiforum123
6 years agoPost Patron
Help required to implement security...
For one of my security requirement. I will have following table as input and thinking of following table as output but dont think that is the optimized way of doing it. For lesser number of records i...
- 6 years ago
Hi pbiforum123
Please see follow the steps in the video.
Best Regards,
Mariusz
If this post helps, then please consider Accepting it as the solution.
Please feel free to connect with me.
LinkedInBest Regards,
Mariusz
If this post helps, then please consider Accepting it as the solution.
Please feel free to connect with me.
LinkedIn
Mariusz
6 years agoCommunity Champion
Hi pbiforum123
Please see the attached file with a Power Query Solution included.
Best Regards,
Mariusz
If this post helps, then please consider Accepting it as the solution.
Please feel free to connect with me.
LinkedIn
Mariusz
If this post helps, then please consider Accepting it as the solution.
Please feel free to connect with me.
- pbiforum1236 years agoPost Patron
Mariusz Please attach the file again to take a look
- Mariusz6 years agoCommunity Champion
Hi pbiforum123
No idea why you can not open the file as just checked and its working fine on my end.
Instead, please see the below M script, you can paste it into the advance editor of a blank query and investigate the steps.
Let me know if you need any assistance.
let Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WSkxKdkjPTczM0UvOz1XSUUpUitWJVkpJTUMRTQKLVlRWoYgqxcYCAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type text) meta [Serialized.Text = true]) in type table [user = _t, group = _t]), #"Renamed Columns" = Table.RenameColumns(Source,{{"group", "_group"}}), #"Replaced Value" = Table.ReplaceValue(#"Renamed Columns","",null,Replacer.ReplaceValue,{"_group"}), groups = List.RemoveNulls( #"Replaced Value"[_group] ), #"Added Custom" = Table.AddColumn(#"Replaced Value", "group", each if [_group] = null then groups else { [_group] }), #"Removed Other Columns" = Table.SelectColumns(#"Added Custom",{"user", "group"}), #"Expanded group" = Table.ExpandListColumn(#"Removed Other Columns", "group"), #"Changed Type" = Table.TransformColumnTypes(#"Expanded group",{{"group", type text}}) in #"Changed Type"Best Regards,
Mariusz
If this post helps, then please consider Accepting it as the solution.
Please feel free to connect with me.
LinkedIn- pbiforum1236 years agoPost Patron
Mariusz Will check and comeback to you again.
Why dont you try sharing the file again? So that i can check one more time.
- pbiforum1236 years agoPost Patron
I am unable to open the attached file. I am getting following error. Please attach it again...