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
Soumya_1998
Regular Visitor

Column Charts

Hi all,

Recently I have tried creating a customized column chart where I have three different columns. 

And I want to create a separate column in that particular panel which would represent the summation of the count of two of the existing columns in the panel. 

Is there any way to reflect that ?

E.g. 

Screenshot 2022-06-05 at 1.13.19 PM.png

 In the above column chart, I want to create a separate column in the panel itself that will be the sum of "count of data.os" of status 684475811 and "count of data.os" of status 684377638.

1 ACCEPTED SOLUTION

hi @Soumya_1998 

 

Yes you can, for example

With this DAX 

Fur-Tech = CALCULATE(SUM(orders_[Profit]),orders_[Category]="Technology" || orders_[Category]="Furniture")
 
I do have Sky Blue color for Technology and Furniture combination and dark blue for actual categories there

 

ribisht17_0-1654421458476.png

 

Looking for a separate Bar itself, in that case

 

Step1

Create a Calculated Table based on these two Status(FILTER), You can give alias as Combined

CALCULATETABLE(Table,Filter)
Summarise it 

SUMMARIZE( <table>, <groupBy_columnName>[, <groupBy_columnName>]…[, <name>, <expression>]…)


where:

  • <table> is a DAX expression that returns with a table of data
  • <groupBy_columnName> is the qualified name of an existing column, which will be grouped based on the internal values.  This parameter cannot be an expression
  • <name> is the name assigned to the new column that will total or summarise data
  • <expression> may be any DAX expression that returns a single scalar value, which will be evaluated multiple times for each row / context. 

>>Understand Summarize DAX function in Power Bi - Power BI Docs

 

Step 2

Union this with your table

Using calculated tables in Power BI Desktop - Power BI | Microsoft Docs

 

Now your table is something like

 

Category

Furniture

Technology

Home office

Combined

 

Now this will act like a regular table with the desired results

 

 

 

Regards,

Ritesh

 

View solution in original post

7 REPLIES 7
ribisht17
Super User
Super User

@Soumya_1998 

 

as mentioned by @AlB , please use Group

ribisht17_0-1654416942474.png

 

Thanks,

Ritesh

 

AlB
Super User
Super User

@Soumya_1998 

You could create a group with those two status values:

https://docs.microsoft.com/en-us/power-bi/create-reports/desktop-grouping-and-binning

 

SU18_powerbi_badge

Please accept the solution when done and consider giving a thumbs up if posts are helpful. 

Contact me privately for support with any larger-scale BI needs, tutoring, etc.

 

Thanks for the solution. 

Actually I also want to keep the other two columns (used for grouping) in the panel. Is there a way to keep them as well along with the grouped column ?

 

hi @Soumya_1998 

 

Yes you can, for example

With this DAX 

Fur-Tech = CALCULATE(SUM(orders_[Profit]),orders_[Category]="Technology" || orders_[Category]="Furniture")
 
I do have Sky Blue color for Technology and Furniture combination and dark blue for actual categories there

 

ribisht17_0-1654421458476.png

 

Looking for a separate Bar itself, in that case

 

Step1

Create a Calculated Table based on these two Status(FILTER), You can give alias as Combined

CALCULATETABLE(Table,Filter)
Summarise it 

SUMMARIZE( <table>, <groupBy_columnName>[, <groupBy_columnName>]…[, <name>, <expression>]…)


where:

  • <table> is a DAX expression that returns with a table of data
  • <groupBy_columnName> is the qualified name of an existing column, which will be grouped based on the internal values.  This parameter cannot be an expression
  • <name> is the name assigned to the new column that will total or summarise data
  • <expression> may be any DAX expression that returns a single scalar value, which will be evaluated multiple times for each row / context. 

>>Understand Summarize DAX function in Power Bi - Power BI Docs

 

Step 2

Union this with your table

Using calculated tables in Power BI Desktop - Power BI | Microsoft Docs

 

Now your table is something like

 

Category

Furniture

Technology

Home office

Combined

 

Now this will act like a regular table with the desired results

 

 

 

Regards,

Ritesh

 

Thank you so much Ritesh ! 

Hi @Soumya_1998 

 

Would you like to mark the answer if it helped you so that it can help others as well

 

Regards,

Ritesh

You are welcome :), 

Mark my post as a solution if it helped you| Munde and Kudis (Ladies and Gentlemen) I like your Kudos!! !!
My YT Channel Dancing With Data !! Connect on Linkedin !!Power BI for Tableau Users 

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.