KNOWLEDGE BASE

Connecting live to PostgreSQL in Tableau Cloud producing different results


Published: 11 Apr 2023
Last Modified Date: 12 Apr 2023

Issue

When connecting live to PostgreSQL database in Tableau Cloud, different results might occur.

Data from Tableau Cloud
User-added image
Data from database
User-added image

Environment

  • Tableau Cloud
  • PostgreSQL

Resolution

As a workaround, in PostgreSQL Connection dialog box, click Initial SQL, and enter the sql command to set the necessary timezone. For example:

SET TIMEZONE TO 'Asia/Shanghai'

Cause

When connecting live to PostgreSQL database via Tableau Cloud, Tableau defaults the timezone settings to UTC to issue the subsequent queries, leading to different data for users collaborating in different timezone/regions.
Did this article resolve the issue?