====== Getting your data into Tableau ====== To use your data in Tableau you will need to follow these steps. Before you get started with these steps please make sure you have your accounts connected in your [[http://onboard.windsor.ai/|Windsor.ai configuration]] To get data from Windsor.ai connectors directly: ==== Connectors ==== - On your [[http://onboard.windsor.ai/|Windsor.ai configuration]] head to **2. Select Destination** and select Tableau - Select the fields you would like to have streamed into Tableau - Copy the URL link shown in the instructions - Open Tableau Desktop, head to Connect > To a Server > More… > Web Data Connector In the window you enter the URL https://tableau.windsor.ai ==== Windsor.ai attribution table ==== To get modelled or transformed data from [[http://charts.windsor.ai|Windsor.ai charts]] * Head to the slice you would like to export into Tableau \\ {{ :charts-to-tableau-1.png?nolink&800 |}} * Customise your slice and then click on the **JSON** button. Now your JSON link is in your clipboard \\ {{ :charts-to-tableau-2.png?nolink&800 |}} * Open Tableau Desktop, go to * Connect * To a Server * More… * Web Data Connector * Enter the URL https://tableau.windsor.ai * In the window which opens, paste the URL link from charts ==== Custom SQL lab queries ==== To get your custom SQL queries into Tableau you will need to convert your query to a dynamic data source. Start by writing your SQL query in [[https://charts.windsor.ai/w/sqllab|SQL lab]]. * Write your SQL query * Click on **EXPLORE** \\ {{ :sqllab-to-tableau1.png?nolink&800 |}} * Give the query a name and click **SAVE & EXPLORE** \\ {{ :sqllab-to-tableau2.png?nolink&800 |}} * From here you can follow the same steps as in the section above (Windsor.ai attribution table) === Formatting of dates from Windsor.ai charts === When working with dates from Windsor.ai charts they are displayed in millis (Epoch format). So your dates will appear in a format like **1609977600000** * To convert dates in Tableau right click on the date you want to format \\ {{ :tableau_dates_1.png?nolink&800 |}} \\ * And format the number using this formula \\ dateadd('second',INT([event date]/1000),#1970-01-01#) \\ {{ :tableau_dates_2.png?nolink&800 |}} === Automatically refreshing data === {{ :refresh_tableau.png?nolink&800 |}} To keep the data refreshed once you publish your report online simply head to **Extract Refreshes** and set up the refresh.