Add variance column to pivot table?

Hello!
I have this simple pivot table but I need to add a new column with the difference between the two Amount columns. Can you please, guide me on how to do it?

Thank you!

Hi @celia.borges ,

You can add a table calculation against the amount field from the Values field well.
Attaching a sample pic :

Thanks,
Prantika

Thank you for your quick response! I implemented your suggestion but I have the scenario where I have in the columns paymentbatchid, so it is adding the calculated column per paymentbatchid. I only need one column at the end of the table to calculate the difference between the two amount values per row. Is there a way to do it?
This is how it looks:

Since you are using a pivot table and have the batchid under columns, I doubt there is a possible way to add single column with difference.

However I have a question, if there are more than 2 batchids, how is the difference computed? If there is always 2 batchids only, then we can achieve this in a table instead of pivot table and create calculated fields for amount 1, amount 2 and difference. Sorry do not have clarity on your use case, so this may or may not work.

I changed to table and added the columns as calculated fields. Thanks for your help!

1 Like