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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
Anonymous
Not applicable

How to make pivot table in power bi as same as excel

I have such data

SunnyRKFOODLAND_0-1667027689548.png

I want it to be like this in power bi so that i can use flow map and use count as width

SunnyRKFOODLAND_1-1667028014174.png

how can i do it help me 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

 

Use group by feature in Power Query Editor:

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WKk4t0DUyUtJRyi7NS8nJBDJK8/IS85VidUaiXGJGbmpKYlJiyqg8Vvns/JzsxJJEymRjAQ==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Month = _t, #"veh location" = _t, #"income location" = _t]),
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"Month", type date}, {"veh location", type text}, {"income location", type text}}),
    #"Grouped Rows" = Table.Group(#"Changed Type", {"Month", "veh location", "income location"}, {{"Count", each Table.RowCount(_), Int64.Type}})
in
    #"Grouped Rows"

vjaywmsft_0-1667380223466.png

 

Best Regards,

Jay

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Hi @Anonymous ,

 

Use group by feature in Power Query Editor:

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WKk4t0DUyUtJRyi7NS8nJBDJK8/IS85VidUaiXGJGbmpKYlJiyqg8Vvns/JzsxJJEymRjAQ==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Month = _t, #"veh location" = _t, #"income location" = _t]),
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"Month", type date}, {"veh location", type text}, {"income location", type text}}),
    #"Grouped Rows" = Table.Group(#"Changed Type", {"Month", "veh location", "income location"}, {{"Count", each Table.RowCount(_), Int64.Type}})
in
    #"Grouped Rows"

vjaywmsft_0-1667380223466.png

 

Best Regards,

Jay

AbbasG
Memorable Member
Memorable Member

@Anonymous In Power BI you can use the Matrix visual to get the desired output.

AbbasG_0-1667050765739.png

 

Anonymous
Not applicable

yes. but I want to use that as a table in the flow map ( Visual Addin) to show A to B traveeling frequency. using matrix can i do that?

lukiz84
Memorable Member
Memorable Member

YourMeasure = COUNT('Table'[Income Location])

Helpful resources

Announcements
June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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