3 Replies Latest reply on Aug 24, 2012 7:40 AM by Tim Latendress

# Simple Calculation in theory, not in Tableau!

Hello,

I have a large table with appointment slots, some of which are booked, some not. The attached pdf shows the count of all appointments by month broken down by whether they're booked or not. I need to show, for each month, the sum of the values in the current and next two months in future so each cell in the table contains the number of appointments for the next 3 months (for example the values in the August cell need to show the number of appointments in Aug, Sep and Oct).

If this was in excel it would be a simple moving sum of 3 cells but I can't figure out how to do this in tableau.

Can anyone help please?

Many thanks,

Steve.

• ###### 1. Re: Simple Calculation in theory, not in Tableau!

Steven,

Create a calcuated field using the Window_Sum function.

WINDOW_SUM(SUM([yourfieldhere]), 0, 2)

Hope this helps.

--Tim

• ###### 2. Re: Simple Calculation in theory, not in Tableau!

Thanks Tim,

That works perfectly, turns out it is simple after all.....

Steve.

• ###### 3. Re: Simple Calculation in theory, not in Tableau!

Steve,

Happy to help.

--Tim