Cross-database Join

In Chapter 1Catching Up with Tableau 2018, about data connection, you saw how to create joins between different Tables of the same dataset. With cross-database Joins, you can create joins between different tables from different connections of different types. It's a great way to add new dimensions to your analysis.

You can't use all the different types of connections in a cross-database Join. A published Data Source, for example, can't be joined.

As an example, let's create a join between Sample-Superstore and another Excel File, Reimbursement, containing the reimbursed orders.

To reproduce the following example, you need to download the Reimbursement Excel file available on the website, book.ladataviz.com, in the Chapter 12 section, or use this link: https://ladataviz.com/wp-content/uploads/2018/09/Reimbursement.xlsx.

Here's what the Reimbursement table contains:

Here's how to create a cross-database Join between those two files:

  1. Open Tableau, and click on the saved Data Source, Sample - Superstore.
  2. Click on Data Source at the bottom-left of the window to open the Data Source workplace.
  1. Next to Connections, click on Add to connect to another File or Server, as highlighted in the following screenshot:

  1. Search and select the Reimbursement Excel File. Tableau automatically opens it in the same Data Source page, underneath Sample - Superstore.
  2. Add the Reimbursement table as a usual left Join:

Each connection has its color, so it's easy to differentiate them.
  1. Create, in a new Worksheet, a visualization that combines the sales and the reason for reimbursement using a single data source:

A cross-database Join has the same disadvantage as a standard join: it can duplicate the data. However, it's a great feature that allows you to combine multiple datasets of different types in a unique Data Source.

The next section presents another way of combining two datasets. 

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.143.22.23