3 Replies Latest reply on Nov 18, 2018 9:04 PM by Shinichiro Murakami

# YTD,MTD,WTD, Year on Year calculation with a 445 calender TYPE

Hi,

We are lukcy enough to use a 445 calendar in my company.

For handle this in Tableau, we have created a customised calendar table used for all our reports.

Attached is a workbook with superstore data & our calendar table.

Below is a screenshot of an extract of the calendar:

I am trying to calculate various time comparison, based on the period (for instance a month) that will be selected by the user.

• Year to date
• Last fiscal year vs this fiscal year, for instance: fiscal year 2018 vs 2017
• Last period vs this current period: for instance Period 12, 2018 vs Period 12, 2017
• last 13 weeks vs last 13 weeks of last year, for instance: from week 30 to week 43 of Fiscal year 2018 vs rom week 30 to week 43 of Fiscal year 2017
• ...

Being a PowerBI users, I am used to playing with calendar table and the ID of each calendar fields (such as period ID, week ID, ...).

But I can't figure out an equivalence in Tableau ?

I have read multiple posts in the forum but could not find the right information.

Woudl you be able to help me or direct me to specific calculations which can handle this ?

Thanks

Patrick

• ###### 1. Re: YTD,MTD,WTD, Year on Year calculation with a 445 calender TYPE

You already have all the dates and rest of the tasks is just based on basic Tableau's table calculations.

Table calc is REALLY flexible, which means really complicated sometimes, but that's different discussion from "fiscal problem", but "Tableau calculation's problem".

In otehr words, normal calendar has similar  problem.

Thanks,

Shin

• ###### 2. Re: YTD,MTD,WTD, Year on Year calculation with a 445 calender TYPE

Would you have any reference I can read on the "Table Caculation's problem" you are referring that will help me to solve my 445 problem?

I am a little bit lost and was not able to efficiently use the specific calendar built.

For instance, I am looking at comparing the last 4 weeks with the same last 4 weeks of last year.

In my calendar, I have the specific week numbers related to our 445 calendar, like W07, W08, W09,...

How can I compare the weeks W07 to W11 of this year vs the same week numbers of last year ?

Thanks a lot for your help,

Patrick

• ###### 3. Re: YTD,MTD,WTD, Year on Year calculation with a 445 calender TYPE

I am not sure what is final expecting viz, but here is an example.

"Label Week Of Year" is common across fiscal year, and you can filter these weeks.

And put "Label Year" as dimension and you will get each year's sale on these 4weeks.

Wen you put quick table calc, you will get delta from last year on same label week.

Thanks,

Shin