Tableau Course
Connecting Data in Tableau
Every Tableau project starts with a data connection — and Tableau can connect to almost anything, from a simple Excel file on your desktop to a live cloud database with millions of rows.
The Data Source Tab
When you click any data source on the Start Page, Tableau takes you to the Data Source tab. This is your connection configuration screen — the place where you tell Tableau exactly what data to load before you start building charts.
The Data Source tab has three main zones. On the left is the Connections panel — it lists your connected files or databases and lets you add more. In the centre is the canvas where you drag tables to define your data structure. At the bottom is a data preview grid showing the first rows of your dataset so you can confirm everything looks right before moving to a worksheet.
Types of Data Connections
Tableau organises its connection types into two broad categories. Understanding the difference before you connect saves time and prevents performance issues later.
Tableau queries the data source directly every time you interact with the view. The data is always current — but performance depends on the speed of your database.
Tableau takes a snapshot of your data and stores it locally as a .hyper file. Queries run against this local file — extremely fast, works offline, but requires manual refresh to update.
For most lessons in this course, a Live connection to the Superstore Excel file is perfectly fine. You will explore Extracts in depth in Lesson 18.
Connecting to an Excel File
Excel is the most common data source for Tableau beginners. Here is the exact process from the Start Page to a loaded worksheet:
The Data Source Tab — Labelled Mockup
Here is a visual breakdown of every area you will use on the Data Source tab when connecting the Superstore Excel file:
| Abc Order ID | 📅 Order Date | Abc Category | Abc Region | # Sales | # Profit |
|---|---|---|---|---|---|
| CA-2023-001 | 01/03/2023 | Furniture | West | 1,200 | 180 |
| CA-2023-002 | 02/03/2023 | Technology | East | 3,500 | 840 |
| TX-2023-041 | 05/03/2023 | Office Supplies | Central | 420 | 96 |
Connecting to a CSV File
Connecting to a CSV file follows the same steps as Excel — with one important difference. A CSV has no separate sheets, so the entire file loads as a single flat table onto the canvas automatically. No dragging required.
On the Start Page, click Text File under the Connect panel, select your CSV, and Tableau places the file on the canvas immediately. The data preview appears at the bottom straight away.
One thing to watch with CSVs: Tableau infers data types from the first rows of the file. If your date column contains even one row with a non-standard format, Tableau may read the entire column as text. Always check the data type icons in the preview before proceeding to the worksheet.
Connecting to a Database
For a database connection — MySQL, PostgreSQL, SQL Server, or others — Tableau asks for a few more details before it can connect. Here is what the connection screen looks like and what each field means:
Once signed in, Tableau lists all available databases and tables in the left panel — just like it lists sheets for an Excel file. Drag the table you need onto the canvas and the data preview appears at the bottom.
Fixing Data Types at the Source
Before leaving the Data Source tab, always scan the data type icons above each column in the preview. Getting data types right here saves you from broken charts and incorrect calculations later. Here is a quick reference for common corrections:
| Symptom in Preview | Likely Cause | Fix |
|---|---|---|
| Sales shows as Abc (text) | Column contains a currency symbol or blank row | Click the Abc icon and change to Number (decimal) |
| Order Date shows as # | Date formatted inconsistently in source file | Click the # icon and change to Date |
| Postal Code shows as # | Tableau treats it as a number, stripping leading zeros | Click the # icon and change to String |
Renaming the Data Source
By default Tableau names your data connection after the file — something like Sample - Superstore.xls. In workbooks with multiple connections, this gets confusing fast. At the top left of the Data Source tab you will see the connection name — double-click it to rename it to something clear like Superstore Orders. This name appears in the Data pane throughout your workbook.
Always spend 60 seconds on the Data Source tab before jumping to a worksheet. Check that column names make sense, data types are correct, and the right table is on the canvas. Fixing a data type issue here takes five seconds. Fixing it after you have built ten charts — when every chart using that field is broken — takes much longer. Treat the Data Source tab as your quality gate, not a screen to click through quickly.
Practice Questions
1. Which connection type queries the data source directly every time you interact with the view in Tableau?
2. What file extension does Tableau use to store a local data extract?
3. A Postal Code field is being read as a number and losing its leading zeros. Which data type should you change it to?
Quiz
1. How does a Tableau Extract connection work?
2. How do you load a sheet from an Excel file onto the Data Source canvas in Tableau?
3. Where in the Data Source tab can you check data types and view the first rows of your connected data?
Next up — Lesson 5: Data types in Tableau — strings, numbers, dates, and booleans, and how each one behaves differently on shelves and in calculations.