Hey guys,
See below my original table. In the grand total section, it shows the data in male and female in different colors.
When I convert the table into a bar graph, the totals stack onto one another, like this:
I would prefer the total has a similar format as my other six regions though...
I'd like the two bars stand side by side like others do; is there a way to do that that?
Thank you so much!
Hi Xiao,
Create sql query as
SELECT [Orders].[Category] AS [Category],
[Orders].[OrderDate] AS [OrderDate],
[Orders].[OrderID] AS [OrderID],
[Orders].[Profit] AS [Profit],
[Orders].[Quantity] AS [Quantity],
[Orders].[Sales] AS [Sales],
[Orders].[Segment] AS [Segment],
[Orders].[SubCategory] AS [SubCategory],
'Data' as [Data]
FROM [dbo].[Orders] [Orders]
Union All
SELECT [Orders].[Category] AS [Category],
[Orders].[OrderDate] AS [OrderDate],
[Orders].[OrderID] AS [OrderID],
[Orders].[Profit] AS [Profit],
[Orders].[Quantity] AS [Quantity],
[Orders].[Sales] AS [Sales],
[Orders].[Segment] AS [Segment],
[Orders].[SubCategory] AS [SubCategory],
'Total' as [Data]
FROM [dbo].[Orders] [Orders]
Create calc as
if ['Data']='Data' then [Category]
else 'Total'
END
Drag created calc and gender into column and sales into row. drag gender into color.
Refer below