Forum Discussion

Alaska1's avatar
Alaska1
Frequent Visitor
1 year ago
Solved

Visuals on more than one column

I have three data columns that I need to create a visual (bar graph or table).  Is there a way to create the chart based on the three columns?

 

Example:

Status 1 

Completed

 

Status 2

Pending

 

Status 3

Escalate

 

  • Alaska1 

    you can try to do the data transform in PQ

     

    let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45Wcs7PLchJLUlNUdJRCkjNS8nMSweyXIuTE3MSS1KVYnVooUQBjLGJEmEqRKNnXjJUljzzKNKCw3JswrEA", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Completed = _t, Pending = _t, Escalate = _t]),
    Custom1 = Table.FromList( List.Combine(Table.ToColumns( Source))),
    #"Filtered Rows" = Table.SelectRows(Custom1, each ([Column1] <> " ")),
    #"Duplicated Column" = Table.DuplicateColumn(#"Filtered Rows", "Column1", "Column1 - Copy"),
    #"Grouped Rows" = Table.Group(#"Duplicated Column", {"Column1"}, {{"Count", each Table.RowCount(_), Int64.Type}})
    in
    #"Grouped Rows"

     

    then it will be easy to draw the pie chart.

     

  • Anonymous's avatar
    Anonymous
    1 year ago

    Hi Alaska1 ,

    Ryan_mayu seems to have provided you with a solution, is it possible to mark his reply as a solution? Also, is there anything else you need help with regarding this thread?

    Best Regards

8 Replies

  • Hello Alaska1 ,
    You might need to transform your data (Unpivot in power query or update directly in excel). Please see below data structure.

    After this you can simply select the type of visual in the below case I have selected clustered column chart and put in field accordingly

    Hope this help!

    • Alaska1's avatar
      Alaska1
      Frequent Visitor
      CompletedPendingEscalate
      CompletedPendingEscalate
      CompletedPendingEscalate
      CompletedPendingEscalate
      Completed  
      Completed Escalate
      CompletedPending 
      Incomplete  
      Completed Escalate
      Completed  
      Completed Escalate
      Completed  
      Incomplete  
      Incomplete  

       

       

      Thank you!

      • ryan_mayu's avatar
        ryan_mayu
        Icon for Super User rankSuper User

        Alaska1 

        you can try to do the data transform in PQ

         

        let
        Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45Wcs7PLchJLUlNUdJRCkjNS8nMSweyXIuTE3MSS1KVYnVooUQBjLGJEmEqRKNnXjJUljzzKNKCw3JswrEA", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Completed = _t, Pending = _t, Escalate = _t]),
        Custom1 = Table.FromList( List.Combine(Table.ToColumns( Source))),
        #"Filtered Rows" = Table.SelectRows(Custom1, each ([Column1] <> " ")),
        #"Duplicated Column" = Table.DuplicateColumn(#"Filtered Rows", "Column1", "Column1 - Copy"),
        #"Grouped Rows" = Table.Group(#"Duplicated Column", {"Column1"}, {{"Count", each Table.RowCount(_), Int64.Type}})
        in
        #"Grouped Rows"

         

        then it will be easy to draw the pie chart.

         

    • Alaska1's avatar
      Alaska1
      Frequent Visitor
      CompletedPendingEscalate
      CompletedPendingEscalate
      CompletedPendingEscalate
      CompletedPendingEscalate
      Completed  
      Completed Escalate
      CompletedPending 
      Incomplete  
      Completed Escalate
      Completed  
      Completed Escalate
      Completed  
      Incomplete  
      Incomplete  

       

       

      Thank you!