If you’re constantly working with data, you know that dashboards are the bread and butter of modern analytics reporting.

 

However, while dynamism is of the essence, it’s increasingly difficult to stay consistent throughout different templates, reports, and visualizations.

 

If you’re looking to create a dashboard that displays your data on an ongoing basis, you need to create a refreshable dashboard.

 

But what if you need a custom date? What if your organization’s preferred format is not a default Tableau template?

 

Luckily, there is a tool for that. The Cognetik Cloud Connector offers a feature called “Date Expression”.

 

With the connector, you can bring all your data together into one unified view in Tableau, by connecting with all your cloud data sources. You can connect many sources, like Adobe Analytics, Google Analytics, Google Ads, DoubleClick, Facebook Pages, Facebook Ads, YouTube, Bing Ads, Twitter Ads, and Kochava.

 

When you submit your query in the Cognetik Cloud Connector, you need to choose one of the rolling dates presets provided in the drop-down menu (Today, Yesterday, This Week, This Month, Two Weeks Prior, Last Week, Last 13 Weeks, Last Month, Last 13 Months, Last 7 Days, Last 30 Days, Last 90 Days, Fixed Start), as opposed to the ‘Fixed End Date’ (refreshing a dashboard with a specific end date will not update your data, as no entries beyond your end date are added).

 

If these options are too limited for you, this is where the ‘Date Expressions’ feature comes in handy (available for any Data Provider supported by our Connector).

How is it used?

 

When choosing the ‘Start Date expression’ and ‘End Date Expression,’ the time period is determined by taking the present day as a starting point, so your limits are written as formulas. This means that the data linked to your date expression will change every day.

 

For example, if you want to query the last 180 days, you can choose ‘Date expressions’ from the ‘Preset’ drop down menu, and use this formula:

 

  • ‘cd-180d’ (current day-180 days) for the ‘Start Date Expression’ field
  • ‘cd’ (current day) for the ‘End Date Expression’ field

Because date ranges must be reckoned relative to the current period, the first term in an expression always begins with ‘c’.

 

For convenience and flexibility, we offer the possibility of using:

 

  • Daily variables (d, as shown in the formula above)
  • Weekly variables (w)
  • Monthly variables (m)
  • Yearly variables (y)  

 

In this sense, ‘cd-7d’ and ‘cd-1w’ are equivalent, as shown in the screenshots below.

Date Expressions & Granularity

 

When using Date Expressions, you can choose your granularity just as you would for a standard preset or fixed dates, as the variable format (d, w, m or y) does not affect your granularity settings. These variables only help you better define your time interval.

 

In order to query the new data, you need to refresh your dashboard data source (manually in Tableau desktop or a scheduled refresh in Tableau Server) periodically.

 

For more info on date expressions and how to use them, you can also visit Adobe’s documentation.

About the author

Sebastian Stan

Sebastian is a journalist and digital strategist with years of experience in the news industry, social media, content creation & management, and digital analytics.

New eBook Release: A Guide to User Journey Analysis

Cognetik eBook: Guide to User Journey Analysis

Related Articles