5 Replies Latest reply on Sep 14, 2016 12:27 PM by nigora.sharipova

    Default Date on Tableau Server




      I have published a report on Tableau Server which gets refreshed on an hourly basis. I would like my default date to be today(); however, Tableau Server defaults the date on the day I have published the report.


      Any suggestions would be much appreciated! 



        • 1. Re: Default Date on Tableau Server
          Andrew Watson

          Set up your report with a relative date filter of today. When you publish a report it maintains the dates which you published - hence it should be published with a relative (green pill) date filter.

          • 2. Re: Default Date on Tableau Server

            Thank you Andrew for your response. I was not able to apply relative date filter of today as i have a metric with a prior four week average calculation. This filter also impacts my calculation. Would you have other suggestions?



            • 3. Re: Default Date on Tableau Server
              Andrew Watson

              Sure, you could use a calculated field to load your measure(s) and also the four week average calc. For example:


              Todays Sales: IF [YourDateField] = TODAY() THEN [Sales] END


              FourWeekAvg: IF [YourDateField] = DATEADD('week',-4,TODAY()) THEN [Sales] END (...or something like this, I don't know the structure of your 4 week average calculation)

              • 4. Re: Default Date on Tableau Server
                panjala Srinath

                Hi nigora.sharipova


                It is very simply that your requirement of filtering is not "mutually exclusive" which create the confusion in logic....


                when you want to apply today() Filter on the tableau report which actually exclude remaining data other than today , that implies your average of last 4 weeks can be calculated since data till yesterday was filtered out.


                Can you please elaborate us with exact data set and requirement for which we can come up with a most probable solution.


                Thanks & Regards


                • 5. Re: Default Date on Tableau Server

                  Hi panjala Srinath,


                  Thanks for your message. I have an hourly report, which refreshes every day on an hourly basis. There are two metrics on each chart: current hour and prior 4wk avg for the same hour. I am using the following date filter to limit my chart to display only one day, but maintain correct prior 4 wk avg calculation:

                  datetrunc('day',lookup(min([Date]),0)) = [Date Range]  Note: Date Range is a parameter which pulls all date values


                  I am using the following formula for the prior 4wk avg calculation:






                  ) /4


                  Currently, the date parameter displayed in the report defaults on the day report was published to the server. I would like the parameter to default on the latest refreshed date (current date) rather than the date the report was published.