Updated on 27 Jul 2021

Integrating SQL and Tableau

Martin Ganchev
Published on 27 Aug 2018 7 min read

By this point, you should be familiar with the CASE statement (if not, you can check out this tutorial first). However, if you want to become a better business intelligence analyst, learning how to integrate SQL and Tableau is key.

sql and tableau

Today, the world of programming gives us the chance to use various technologies allowing us to approach and solve diverse kinds of problems.

More precisely, programming allows us to connect and exchange information between servers, software applications and frameworks operating in different domains.

The Various Strong Points of Different Programming Languages

For example, SQL is a language that has been specifically designed for the domain of relational database management systems.

specifically designed for the domain of the RDBMS

In contrast, the strong points of programming languages like R and Python are the execution of complex mathematical computations and their application in the sphere of business, statistics, and finance. C++, instead, is ideal for creating various sets of software tools, ranging from operating systems to graphic design applications.

C++ R Python

User-Friendly Applications

Then, you could come across software applications that are more user-friendly, while at the same time delivering the exact type of output required for your job. For instance, Tableau is a software used massively in business intelligence and analytics, as it provides a wide range of visualizations of datasets.


The Structure of Programming Languages

During the last few decades, the list of programming languages and software applications has grown so much that it seems to be endless.

hadoop scala java excel

Nevertheless, when we look more closely, we can see that each of these technologies boils down to the following structure: they involve the administration and manipulation of a given amount of data to produce a specific type of output that will help businesses improve decision making.

admin to output to improve decision making, sql and tableau

The Abundance of Software

So, when we look at the bigger picture, we can see that today there’s an abundance of software, each relevant for its domain. And from a technological perspective, this is amazing. But what does the picture look like from a business point of view?

Solving a Business Task

Well, imagine you want to solve the following business task:

create a bar chart showing the breakdown of male and female workers in a company

If you have your data in Excel, that seems to be an easy one. You can select the columns containing the data of interest, and then insert a chart or graph to your liking.

The Problem with Using Excel

However, this will not always happen in real life. Companies are often using one software tool for database administration, another tool for computations, one for visualizations and so on.

data admin computations visualisations

The reasons for using a variety of tools can be numerous:

  • to optimize the capacity of the chosen software
  • practical reasons
  • cost reduction
  • data security
  • historical reasons
  • or simply because a tool which deals with all domains together does not exist!

Connecting Programming Languages and Tools

Here comes the good news. All these software applications and languages are not living alone, they are not detached from the entire ecosystem.

server connection

They can be connected, and they can communicate. That is, they can exchange information with one another.

And if the thought that comes to your mind right now is that you would probably need to implement some sort of integration, then you are spot on. In programming terms, you can integrate two or more programming languages and tools, with the idea of extracting a particular type of output.  

How to Integrate SQL and Tableau?

SQL and Tableau can be integrated. This means that these two tools can serve a common goal.

sql and tableau can be integrated and serve a common goal

The goal is namely answering such business questions as the one we mentioned before.

To begin, you can store a very large amount of data in a database. Then, you can manipulate it with SQL. So, using this language, you can create and maintain the foundations of your analysis.


However, looking at hundreds and hundreds of thousands of rows of numbers and text is typically not so helpful when you are trying to interpret this data.

The Role of Tableau

This is where Tableau can help. Its main functions include quickly connecting to a server such as the SQL server, extracting the necessary data, applying relevant calculations, and then visualizing the obtained information.

calculate and visualise

Speaking in a more technical language, we can say this software will let you create:

  • graphs
  • chart
  • reports
  • dashboards

All of these operations are a must for any business intelligence analyst out there. In fact, it is namely the reports and the dashboards that allow end users such as company executives and general managers to understand the core of a business and extract insights about it.

Why Connect SQL and Tableau?

To conclude, integrating SQL and Tableau is about taking our data from the depths of our database to its esteemed, beautiful representation in Tableau. Doing this will assist us in working smarter, not harder.

Continue to the next tutorial to learn how to set up a database in SQL.


Eager to hone your SQL skills? Learn how to put theory into practice with our hands-on tutorials!

Next Tutorial: Set up a Database in SQL

Learn data science with industry experts

Try For Free
Martin Ganchev

Instructor at 365 Data Science

Martin holds an MSc degree in Economic and Social Sciences from Bocconi University. His diverse academic and research experience combined with his friendly and explanatory approach to teaching have made him one of the most beloved instructors on our team. Some of the courses he has authored include: SQL, SQL + Tableau, SQL+Tableau+Python, Introduction to Python, Introduction to Jupyter, to name a few.