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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
larabraghetti
Helper II
Helper II

New Table for another one with Count

Hi all,

 

in PowerBI, I have a table like this one:

Immagine1.JPG

 

And I need to create a new table like this one:

immagine2.JPG

 

I need this 2nd table in order to built a new cascade graph.

Someone could help me?
Thank you very much in advance!
Ciao!
Lara

1 ACCEPTED SOLUTION
CheenuSing
Community Champion
Community Champion

@larabraghetti

 

Please try the following

 

1. After the intial load of the table, right click on the table and select Edit Query

2. This will take you to QueryEditor

3. Go to the transform tab

4. Select the three columns of the table Opened atStartDate,OpenedThisMonth, ClosedThisMonth

5. Choose the icon a2 UnpivotColumn from the AnyColumn area

    GroupNameSlicer.GIFGroupNameSlicer.GIF

6. The Output of your intial table will be like

7. Click on File --> Close and Apply

8. Now create the newTable as 

    NewTable = Summarize( OpenClosed,[Attribute],"Counts",Calculate( Countrows(OpenClosed),

                                       OpenClosed[Value] ="Yes" || OpenClosed[Value] ="Opened" )   )

9. When you plot the columns from the NewTable in a Table Report Visual, the output will be as you desired.

 

  GroupNameSlicer.GIF

 

If this solves your issue please accept this as a solution and also give KUDOS.

 

Cheers

 

CheenuSing

    

    

 

Did I answer your question? Mark my post as a solution and also give KUDOS !

Proud to be a Datanaut!

View solution in original post

4 REPLIES 4
CheenuSing
Community Champion
Community Champion

@larabraghetti

 

Please try the following

 

1. After the intial load of the table, right click on the table and select Edit Query

2. This will take you to QueryEditor

3. Go to the transform tab

4. Select the three columns of the table Opened atStartDate,OpenedThisMonth, ClosedThisMonth

5. Choose the icon a2 UnpivotColumn from the AnyColumn area

    GroupNameSlicer.GIFGroupNameSlicer.GIF

6. The Output of your intial table will be like

7. Click on File --> Close and Apply

8. Now create the newTable as 

    NewTable = Summarize( OpenClosed,[Attribute],"Counts",Calculate( Countrows(OpenClosed),

                                       OpenClosed[Value] ="Yes" || OpenClosed[Value] ="Opened" )   )

9. When you plot the columns from the NewTable in a Table Report Visual, the output will be as you desired.

 

  GroupNameSlicer.GIF

 

If this solves your issue please accept this as a solution and also give KUDOS.

 

Cheers

 

CheenuSing

    

    

 

Did I answer your question? Mark my post as a solution and also give KUDOS !

Proud to be a Datanaut!

@CheenuSing Thank you!

 

The problem is that the column used in my first table are Calculated Column.
There is no possibility to have these columns in the queryeditor. (only if I add the columns from there I think...)

See if you can use the concept to derive the final output from the base source table instead of from intermediate table as posted by you.

 

Cheers

 

CheenuSing

Did I answer your question? Mark my post as a solution and also give KUDOS !

Proud to be a Datanaut!

@larabraghetti

 

See if you can use the concept to derive the final output from the base source table instead of from intermediate table as posted by you.

 

Cheers

 

CheenuSing

Did I answer your question? Mark my post as a solution and also give KUDOS !

Proud to be a Datanaut!

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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