When I started using tableau, all I knew was how to connect tableau with few data sources (mostly Excel and CSV) files and make a viz out of that data and then upload the same on tableau public for other to view.
But, recently I got to know that this wasn't all. I got to know that there are various ways of making data live and also that it needs to be refreshed if the data is such that it keeps changing and needs to get refreshed at some interval. It felt like a whole new world of tableau opened up to me.
So, today in this blog, I'll be telling you all the entire process from connecting to a database to making the data live and putting it on refresh on tableau online.
Step 1: Connect to a data source. It could be anything from the list of connections tableau provides. In our case, I'll be using PostgreSQL.
Step 2: Select the kind of connection you would like to keep. Live connection is usually not preferred since it makes the processing slow and also, whenever there is any change in the underlying data query which was a mistake, it would immediately be reflected online which could be a problem. So, I'll go with extract data.
Step 3: A very important thing to note here is that, you should always publish the extracted data source online before you start making any changes in the data as such as creating any calculated fields or anything. Now, why am I saying it's so important is because right now the extracted data is a raw form of your data on which future changes will be made. If we first make any calculated fields or anything and then upload it online, every time we need to make any changes in those calculated fields, we will have to edit a copy of the same and not the actual field which creates a huge problem if that field is being used in multiple places in your viz.
I can't even count the number of times I've cried or cursed myself for not uploading it before making any changes.
Step 4: This step can be done only if you're logged into Tableau Online. Once you're logged in, go to tableau desktop and click on server and publish the required data source.
Step 5: Publish the data source and you will be directed to tableau online automatically.
The above is what you will be redirected to. Right now, it shows 0 extract refreshes because although the extracted data is uploaded, it hasn't been put to a refresh yet.
Step 6: Click on New Extract Refresh. There are 4 interval options you get, Daily, Hourly, Weekly and Monthly. Depending on your need, you can select the interval and also the time at which the refresh should start happening. You can also select the days of a week on which you want the refresh to happen.
For my purpose, I chose hourly extract which would start at 12:55 AM everyday and end at 11:55PM on all weekdays.
Now you can sit back and keep working on your viz and your data will keep getting refreshed with new data or changes at whatever interval you've chosen.
Tableau also sends you mail if the data was not refreshed and it faced an error.
I hope this blog was helpful to you.
You can reach out to me on any of my social media handles and I would be happy to discuss any doubts or suggestions.
Thank You!
Comments