10 Replies Latest reply on May 10, 2018 7:29 AM by Shinichiro Murakami

# Calculating remaining days in the quarter, then divide a figure by the remaining days

Good morning,

I am running into an issue of using the remaining days in the quarter calculated field.

I was able to successfully create a calculated field to determine the remaining days in the quarter. However when I try to divide a figure, which in this case is our quarterly plan minus QTD revenue, by the remaining days in the quarter, I do not get an exact number. I am trying to determine our re-forecasted plan figure for the remaining days in the quarter in order to reach our quarterly plan.

Thanks,

• ###### 1. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

Hi Darren

Could you please attach sample data with TWBX format.

Regards,

Shin

• ###### 2. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

Hi Shin,

The packaged workbook is too large to attach here. I uploaded the file and can be downloaded here. https://ufile.io/cla42

Thanks,

• ###### 3. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

HI Darren,

We only need the smallest set of data to understand your issue, because it's too difficult to investigate your issue without any data.

Could you mock up sample data to replicate your issue.

That's way faster than we speculate your data structure and  create sample data.

Thanks,

Shin

• ###### 4. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

Shin,

I've consolidated the workbook. Please see attached for an example mock up.

Thanks,

• ###### 5. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

HI Darren,

You calc logic is already quite complicated and I cannot dig in very in detail, but guessing below has problem?

Thanks,

Shin

• ###### 6. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

Shin,

I see what you have pointed out, after fixing this, I don't believe that is the issue. See my attached screenshot and workbook for more details. It seems like the issue I'm running into is that the QTD revenue isn't continuing to sum each day and is its own figure for each separate date. And the reforecasted daily revenue (QTD) field is not calculating correctly. Could it be because the days left in the quarter is a dimension and not a metric? When I change this to a metric, it seems likes counting each row that has a date as the number is obscurely high.

Let me know if this makes sense.

Thanks,

• ###### 7. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

HI Darren,

Not quite sure but is this what you expect/

Thanks,

Shin

• ###### 8. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

Shin,

We are getting very close to the answer! The reforecasted number is calculating correctly now. However, in order to show the true reforecasted number for a certain date, I am trying to get a running total sum with QTD revenue. As you can see each row is its own value and not true to QTD revenue and really it should be a running total.

Thanks,

• ###### 9. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

Shin,

After playing around with this, it now works as it should. This has been resolved.

Thank you,

• ###### 10. Re: Calculating remaining days in the quarter, then divide a figure by the remaining days

HI Darren

You are welcome.

Thanks,

Shin