Blogs / Tableau / Performance Enhancement for Live Connection in Tableau – Assume Referential Integrity

Performance Enhancement for Live Connection in Tableau – Assume Referential Integrity

Apr 12, 2019

SHARE

Using a live connection in Tableau for connecting to databases with millions of records poses a big challenge, Performance. Many performance enhancement techniques and features can be implemented to address this issue. In this blog we will cover one of the features, Assume referential integrity.

What is Assume referential integrity?

Enabling this option in Tableau creates joins in the back end only between the tables that contain the dimensions or measures used in the sheet.

Note: The option is useful only when inner join exists between the tables.

Let’s try to understand with an example. The data source used in this example is the liquor sales dataset. Create a star schema for the above dataset and join the tables as shown below:

Performance Enhancement for Live Connection in Tableau – Assume Referential Integrity
Image 1

Start the performance recording and build sales by county bar chart. After the chart is built stop the performance recording

In our sheet we have utilized Country dimension from SS_LOCATION_IOWA_LIQOUR table and the Bottle sold measure from SS_FACT_IOWA_LIQOUR table.

Performance Enhancement for Live Connection in Tableau – Assume Referential Integrity
Image 2

The query in the above image can be obtained from the workbook generated after stopping performance recording.

Even though only two tables are utilized to build the chart query in the back end will be run joining all the tables in the data source. This adds unnecessary and additional load in computing and executing the query.

We can avoid this by enabling assume referential integrity option from the data source tab.

Performance Enhancement for Live Connection in Tableau – Assume Referential Integrity
Image 3

After enabling the option, repeat the same steps as earlier. From performance recording workbook we get the following output:

Performance Enhancement for Live Connection in Tableau – Assume Referential Integrity
Image 4

After enabling assume referential integrity we can see from the above image that for the chart created only the relevant tables are joined, that is, only the tables that contain County and Bottle sold fields are joined. Thus, this option helps in improved performance by joining only the necessary tables when a live connection to a database is used.

* * *

Learn more about Visual BI’s Tableau consulting & end user training programs here.


Corporate HQ:
5920 Windhaven Pkwy, Plano, TX 75093

+1 888-227-2794

+1 972-232-2233

+1 888-227-7192

solutions@visualbi.com


Copyright © Visual BI Solutions Inc.

Subscribe To Our Newsletter

Subscribe To Our Newsletter

Join our mailing list to receive the latest news and updates from our team.

You have Successfully Subscribed!

Share This!

Share this with your friends and colleagues!