Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
ashikts
Helper II
Helper II

table view

Hello Folks, Thanks for the support for a beginer . Need a help with simple task.

 

I have data like this .

CategoryProduct
Fruitmango
fruitbanana
Vegetablepotato
Vegetabletomato

 

and i want the result like this in table view 

 

CategoryProduct
Fruitmango,banana
Vegetablepotato,tomato

 

how i can achieve this . thanks in advance 

1 ACCEPTED SOLUTION
camargos88
Community Champion
Community Champion

@ashikts ,

 

Try this mcode:

 

 

 

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45Wck4sSU3PL6pU0lEKKMpPKU0uUYrViVZyKyrNLAGK5SbmpeeDRdKgIkmJeUAIFgpLTU8tSUzKSQUKF+SXJJbkYwiX5OeChWMB", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [#"(blank)" = _t, #"(blank).1" = _t]),
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"(blank)", type text}, {"(blank).1", type text}}),
    #"Promoted Headers" = Table.PromoteHeaders(#"Changed Type", [PromoteAllScalars=true]),
    #"Changed Type1" = Table.TransformColumnTypes(#"Promoted Headers",{{"Category", type text}, {"Product", type text}}),
    #"Capitalized Each Word" = Table.TransformColumns(#"Changed Type1",{{"Category", Text.Proper, type text}}),
    #"Grouped Rows" = Table.Group(#"Capitalized Each Word", {"Category"}, {{"Rows", each Text.Combine(_[Product], ","), type text}})
in
    #"Grouped Rows"

 

 

 

Capture.PNG

 



Did I answer your question? Mark my post as a solution!

Proud to be a Super User!



View solution in original post

2 REPLIES 2
camargos88
Community Champion
Community Champion

@ashikts ,

 

Try this mcode:

 

 

 

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45Wck4sSU3PL6pU0lEKKMpPKU0uUYrViVZyKyrNLAGK5SbmpeeDRdKgIkmJeUAIFgpLTU8tSUzKSQUKF+SXJJbkYwiX5OeChWMB", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [#"(blank)" = _t, #"(blank).1" = _t]),
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"(blank)", type text}, {"(blank).1", type text}}),
    #"Promoted Headers" = Table.PromoteHeaders(#"Changed Type", [PromoteAllScalars=true]),
    #"Changed Type1" = Table.TransformColumnTypes(#"Promoted Headers",{{"Category", type text}, {"Product", type text}}),
    #"Capitalized Each Word" = Table.TransformColumns(#"Changed Type1",{{"Category", Text.Proper, type text}}),
    #"Grouped Rows" = Table.Group(#"Capitalized Each Word", {"Category"}, {{"Rows", each Text.Combine(_[Product], ","), type text}})
in
    #"Grouped Rows"

 

 

 

Capture.PNG

 



Did I answer your question? Mark my post as a solution!

Proud to be a Super User!



@camargos88  thank you so much sir

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors