This content has been marked as final.
Show 2 replies

1. Re: Calculating percent of total when SUM is different from total  Tableau 10.1
Shinichiro Murakami Feb 16, 2017 1:27 PM (in response to Erik Nelson)Hi Erik,
Here is one idea.
[Group 2]
if contains([Group],"ALL") then "Total" else "Individual" end
[Percent Contribution]
SUM([Sales])/attr({fixed:sum(if [Group 2]="Total" then [Sales] end)})
Overview: Level of Detail Expressions
Thanks,
Shin

2. Re: Calculating percent of total when SUM is different from total  Tableau 10.1
Stephen Shepperd Feb 16, 2017 1:31 PM (in response to Erik Nelson)Hey Erik,
Here's a simple idea. What you can do is write a calculation that takes the sales of each group and divides it by the WINDOW_MAX which is always going to be the "All groups" value. It will look like this:
SUM([Sales])/WINDOW_MAX(SUM([Sales]))
Then you can just change the number format to show in percentages and you should be done!
Hope this helps!