Professional Documents
Culture Documents
1. Connect to a File: This section helps you to connect with Files, or allows you to extract data from files
such as Excel, Text Files, PDFs, Spatial Files etc.
2. Connect To a Server: This section helps you to connect with the Servers, or allows you to extract data
from servers such as MySQL, SQL Server, Tableau Server etc.
3. Saved Data Sources: All the existing or Saved Data Sources will be displayed under this section.
4. Open: Most recently used Workbooks will be displayed under this section. Currently, we don’t have any
used workbooks.
5. Sample Workbooks: These are sample workbooks that will come with Tableau Desktop installation.
6. Training and Resources: Links to Useful Blogs and some videos.
7. Content produced by the tableau Community
Selecting the Data Source will open a New Sheet to create a Report. Here, you can see
the Measures, and Dimensions that are available in this data source.
Tableau Show Me
Show Me window holds most commonly used charts in Tableau. You can use any of these
charts to view the data.
1
3
5. Data Interpreter: If Tableau discovers the format of any column data in our selected
sheet is difficult to analyze, Tableau will pop up a message asking us to Turn On Data
Interpreter. By turning Data Interpreter on, we can normalize the data
Connecting to Text File in Tableau
Once you click on Info button, a new drop-down window will open to configure the
following items:
Does the file includes field names in the First Row?: We have to specify,
whether the selected text file contains column names in the first row or not. By
default, this option is selected as YES but change as per your file requirements.
Filed Separator: Please select the character that is used to separate the columns
in the text file. If the character is not present in the list, select Other and type a
custom character.
Text Qualifier: Please specify the text qualifier used to encloses values in our
selected Text File.
Character Set: Please select the character set that describes the text file encoding.
Locale: Language used to parse the Text File. Tableau will use this to separate the
numbers etc
Connecting Tableau to SQL Server
select and Right Click on the Hierarchy member, select the hierarchy option and
then Remove from hierarchy option from the context menu
Tableau Bins
Tableau Bins are useful to create a Range of data, which is similar to SQL Buckets
To create bins in tableau, we are going to write the Custom SQL Query against the SQL
Server Data Source
SELECT Prod.Productkey,
Prod.EnglishProductName,
Prod.Color,
Prod.DealerPrice,
Fact.OrderQuantity,
Fact.TotalProductCost,
Fact.SalesAmount
FROM DimProduct AS Prod
INNER JOIN FactInternetSales AS Fact
ON Prod.ProductKey = Fact.ProductKey
Drag and Drop the Sales Amount from Measures Region to Filed region.
Right-click on the Product Key dimension and select Create option and then
select Bins option from the context menu.
If you don’t know the bin size then click on the Load button. By clicking this button, the
Tableau desktop will display the Minimum, Maximum, Difference values and also the best
possible Bin size.
Please replace Product Key dimension with Product Key Bin on Row Shelf.
You can observe that Product Key Data is organized into Buckets and the total rows are
21 only.
To display the product keys available in each bin, Drag and Drop the Product key
dimension to the Row Shelf
Select the Bin you want to delete and right-click on it will open the context menu. From the
context menu, Please select the Delete Option.
Default Bar Chart with Color dimension on Row Shelf and Sales Amount on Column Shelf
Right Click on the Sales Amount Measure and select Create Bins option from the menu.
Now, we are using the default bin size generated by the Tableau Desktop
Next, Drag and Drop the newly created Sales Amount bin from Dimension region to
the Color Option in Marks Card. Once you are done, You can see the Stacked Bar Chart.
Let us add the Data Labels and see, whether we successfully created the stacked bar
charts using the Tableau Bins or not
How to Join Data in Tableau
1) Inner join
2) Left Join
3) Right Join
4) Full outer join
NOTE: Using this Join in Tableau method, you can join more than two tables. Please be
careful with complex joins, it will be difficult to understand the data.
For this Tableau data blending demo, we are going to use the data present in Excel
Worksheet and SQL Server.
Our requirement is to create table report with employee first name, last name, occupation,
Sales and yearly income.
Scenario: Suddenly, Client changed the requirements and asked us to add department
and Salary Hike percentage details for every Employee. Here the real problem is,
department and Salary Hike percentage data are present in the Master SQL Server
database. It means, we have to combine few columns from Local Excel Sheet and few
from SQL Database. This is what we call as Tableau Data Blending
Let us add the Department name to the Rows Card. From the below screenshot you can
observe that Tableau is displaying little orange tick mark at department name and also
displaying the warning message.
If you read the warning message, it is a pretty straightforward message saying that there
is no relation between Employees and department. Relationship is very important in
Tableau data blending so, please add the relation.
Primary Data Source: Data Source from which we first dragged the fields
(Dimension or Measure) into report region is called as a Primary data source.
Tableau will display little Blue tick mark beside this data source
Secondary Data Source: Data Source which is not primary. Tableau will display
little orange tick mark beside secondary data source
Automatic: If there are any common Filed names in both the data sources then
tableau will automatically detect the possible relationship between those two fields.
Custom: If there are no common Filed names in the data sources, We have to
select the Custom option and add the relationship between them. For now, we are
selecting this option
Once you specified the relationship, tiny URL link will appear beside the Id column. Click
the link button to enable Data blending in tableau.
When you click the link button, link button colour will change to Orange colour and Our
Department column is displaying data.
Remember, If there are no matching records in Department then Null values will be
displayed.
Once you selected the Aliases.. option, a new window will popped up to rename the filed.
Let us change the Id Column to Dept ID
Tableau will automatically detect the relationship between Dept ID in Employee table and
Dept ID in Department table. It means you don’t have to create a relationship on your own.
You can observe that tiny URL link will appear beside the Dept ID column. Click the link
button to enable Tableau Data Blending
Next, One more warning message which we have seen before. Once you click OK button,
Tiny URL link will be removed besides the Id column as shown below.