1 2 Previous Next 18 Replies Latest reply on Nov 14, 2018 1:15 PM by Mohamed Hersi

# Cannot Do Further Calculation on an Aggregate Value

Dear All,

I need to perform the following in calculated column:

A = (B - C)/B

Tableau shows the following error message:

'An Aggregate function is already and aggregate and cannot be further aggregated'.

Any solution?

• ###### 1. Re: Cannot Do Further Calculation on an Aggregate Value

What code does A,B,C contains ? Do you want this calculated field to be a boolean ?

• ###### 2. Re: Cannot Do Further Calculation on an Aggregate Value

using superstore data set,if you assuming Sales as B and Profit as C then observe below image.please attach your workbook.

• ###### 3. Re: Cannot Do Further Calculation on an Aggregate Value

Hi Sravani,

Hope this helps,

BR,

NB

• ###### 4. Re: Cannot Do Further Calculation on an Aggregate Value

Hi NB,

• ###### 5. Re: Cannot Do Further Calculation on an Aggregate Value

Thanks all for the responses. I still have the problem. I have attached a picture of the sort of data I am working on. I need to create column H (Drop Out Rate Penta1-Penta3) as a percentage.

Regards

• ###### 6. Re: Cannot Do Further Calculation on an Aggregate Value

What is the calculation you're using in tableau to achieve this ?

• ###### 7. Re: Cannot Do Further Calculation on an Aggregate Value

Hi Ombir,

The formula is: Dropt Out Rate = (Penta1- Penta3)/Penta1 *100

I used the following calculation methods:

Method 1: SUM([Penta1 <1])-SUM([Penta3 <1])/SUM([Penta1 <1])

Method 2: ([Penta1 <1]-[Penta3 <1])/[Penta1 <1]

Method 3: [Penta1 <1]-[Penta3 <1]/[Penta1 <1]

All of them resulted large numbers before I even multiplied by 100.

Regards

Mohamed

SUM([Penta1 <1])-SUM([Penta3 <1])/SUM([Penta1 <1])

• ###### 8. Re: Cannot Do Further Calculation on an Aggregate Value

When you say 'All of them resulted large numbers before I even multiplied by 100'. What does it exactly means ? Is your earlier error solved now ?

Is Penta1 and Penta3 are real columns in your data or these are also calculated fields. If yes, then what is the calculation of Penta1 and Penta3 ?

Can you attach a sample workbook so it will be easier to help ?

• ###### 9. Re: Cannot Do Further Calculation on an Aggregate Value

Hi Ombir,

I have created a sample workbook to share but there in no option to attach (only images, URL etc are available for me). So I have attached images of the three methods I have used and the resulting figures per method. Note that in Marks area, I have right-clicked each aggregate > Format > Axis > Scale then converted the numbers into percentages.

• ###### 10. Re: Cannot Do Further Calculation on an Aggregate Value

Hi Ombir,

Just one more important point. This is the formula that I need to use:

(Penta1 - Penta3)/Penta1*100

• ###### 11. Re: Cannot Do Further Calculation on an Aggregate Value

When you reply to a post then you'll find "Advanced editor and add an attachment" on upper right corner. Click that and you'll find Attach option in lower right corner to attach your workbook.

• ###### 12. Re: Cannot Do Further Calculation on an Aggregate Value

As you can see below screen shot, 'Advance Editor' is available to me.

• ###### 13. Re: Cannot Do Further Calculation on an Aggregate Value

I mean Advance Editor NOT available to me.

• ###### 14. Re: Cannot Do Further Calculation on an Aggregate Value

I think that link is not available because javascript is disabled in your browser. Can you try in different browser or attach the file in some other file sharing site like file.io - Ephemeral file sharing

1 2 Previous Next