Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredJoin us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.
Solved! Go to Solution.
Yes, please check out this video:
Just select the other column as well in the last step when you select which fields to show.
Imke Feldmann (The BIccountant)
If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!
How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries
Yes, that's most likely the reason then. You need to reference your original table there whose other values you want to show/expand. If it is not the Source-step, then you have to find the stepname in your query where the data is in the shape that you can use here.
This is the place where your original table will be merged back to the grouped results and you need to join it on the Id-columns of both tables.
Imke Feldmann (The BIccountant)
If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!
How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries
try this:
let Source = YourData, #"Grouped Rows" = Table.Group(Source, {"Id"}, {{"Sum", each List.Sum([amount]), type number}}), #"Added Custom" = Table.AddColumn(#"Grouped Rows", "Group", each "The sum of this group is "&Text.From([Sum])), #"Merged Queries" = Table.NestedJoin(#"Added Custom",{"Id"},Source,{"Id"},"NewColumn",JoinKind.LeftOuter), #"Expanded NewColumn" = Table.ExpandTableColumn(#"Merged Queries", "NewColumn", {"amount"}, {"amount"}) in #"Expanded NewColumn"
Imke Feldmann (The BIccountant)
If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!
How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries
Hi @ImkeF,
Sorry, i'm new to power queries. Could you please send screen shots for each of the steps you have mentioned. I grouped the rows, but could not categorise each row and then merge that into the main data table.
Appreciate if you could send it in screen shot format.
Thanks
Hi @ImkeF,
Ok so I managed to do it somehow until expended columns. However, how do I get back the original source table view? there are many other columns in the source table that I need to use. Just want to ensure it's all in one table including the new categorisation exercise.
Thanks.
Yes, please check out this video:
Just select the other column as well in the last step when you select which fields to show.
Imke Feldmann (The BIccountant)
If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!
How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries
Hi @ImkeF,
Thanks for that. Few clarifications -
1. I have many other columns in the table that I do not see after merging. Like for instance, I have country name, sales rep name, product name etc etc (which was not in my sample data example). So, how do I view all these columns again after expanding in the last step? When I click on the expand option, I only see the new added custom / conditional column and the IDs.
2. Instead of adding "custom" column,.. I chose to add conditional column and stated if value is below 100, catergory is small value, if below 500, middle value, above 500, high value etc etc. It seemed to work fine as an added column. But i cant seem to get back all other various columns that I need from the data source.
Thanks,
could you please upload your file or post screenshots or a video as well?
Imke Feldmann (The BIccountant)
If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!
How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries
Hi @ImkeF,
Yes, will try and upload a video. But one more clarification I needed, just incase i'm missing something from your video. I find just before the expand step, you change the #"Added Custom" to Source. When I try and do that, it gives me an error to say - "The column 'Id' of the table wasn't found." Any way I can fix this? May be it will work then.
Yes, that's most likely the reason then. You need to reference your original table there whose other values you want to show/expand. If it is not the Source-step, then you have to find the stepname in your query where the data is in the shape that you can use here.
This is the place where your original table will be merged back to the grouped results and you need to join it on the Id-columns of both tables.
Imke Feldmann (The BIccountant)
If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!
How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.
User | Count |
---|---|
80 | |
40 | |
31 | |
27 | |
27 |