Book Image

Tableau Prep Cookbook

By : Hendrik Kleine
Book Image

Tableau Prep Cookbook

By: Hendrik Kleine

Overview of this book

Tableau Prep is a tool in the Tableau software suite, created specifically to develop data pipelines. This book will describe, in detail, a variety of scenarios that you can apply in your environment for developing, publishing, and maintaining complex Extract, Transform and Load (ETL) data pipelines. The book starts by showing you how to set up Tableau Prep Builder. You’ll learn how to obtain data from various data sources, including files, databases, and Tableau Extracts. Next, the book demonstrates how to perform data cleaning and data aggregation in Tableau Prep Builder. You’ll also gain an understanding of Tableau Prep Builder and how you can leverage it to create data pipelines that prepare your data for downstream analytics processes, including reporting and dashboard creation in Tableau. As part of a Tableau Prep flow, you’ll also explore how to use R and Python to implement data science components inside a data pipeline. In the final chapter, you’ll apply the knowledge you’ve gained to build two use cases from scratch, including a data flow for a retail store to prepare a robust dataset using multiple disparate sources and a data flow for a call center to perform ad hoc data analysis. By the end of this book, you’ll be able to create, run, and publish Tableau Prep flows and implement solutions to common problems in data pipelines.
Table of Contents (11 chapters)

Connecting to Tableau extracts

Tableau has two popular proprietary data types, Tableau Data Extract (.tde) and Tableau Hyper Extract (.hyper). Neither format can easily be read, if at all, by most data pipeline and ETL tools. With Tableau Prep Builder, however, you can easily use a Tableau data extract as an input into your flow. In this recipe, we'll connect to a hyper extract. The steps are identical when connecting to a TDE extract.

Getting ready

To follow along with this recipe, download Sample Folder 2.6 from the book's GitHub repository.

How to do it…

To get started, ensure you have Tableau Prep Builder open, then follow these steps:

  1. From the home screen, click the Connect to Data button. From the Connect pane, select Tableau extract. This connection type is suited to both TDE and hyper extracts.
  2. From the file browse dialog, select and open our Hyper file named Superstore Sales.hyper.
  3. When the hyper extract has a single table, Tableau Prep will automatically add that table to our flow. If the extract has multiple tables, all we need to do is drag the desired table onto our flow canvas to complete the connection. In this example, the extract contains a single table and is added to the flow by Tableau, completing our input configuration:
Figure 2.27 – Completed connection to Tableau extract

Figure 2.27 – Completed connection to Tableau extract

By following the steps in this recipe, you have learned how to connect to a Tableau extract.

How it works…

As you've seen in this recipe, connecting to Tableau extracts is very straightforward, as you might expect from the company's own data source type. If you're fully into the Tableau ecosystem and using products such as Prep, Desktop, and Server, extracts are a great way to manage data and performance.