You can connect and directly query your data via SQL using Tableau.

For security reasons we do not allow many of the database operations that Tableau expects to be able to do. However you can configure Tableau to connect to our Direct Access server using a Tableau Data-connection Customization file, or TDC.

Download and unzip: deltadna. Once you have extracted the deltadna.tdc file move it into the Datasources directory in your Tableau Repository (For Windows this is usually Documents/My Tableau Repository/Datasources/). Tableau will now use this file to configure PostgreSQL connections. Please make sure to use a PostgreSQL driver >= 10.01 this can be downloaded here.

Once you have saved the .tdc file into your repository, start Tableau and click Connect to data.

Under the To a server heading find the PostgreSQL option

PSQL

Fill in the details for the connection to PostgreSQL:

Enter “data.deltadna.net” for the server with port 5432.

The username and password will be the same details you use to connect to the deltaDNA platform.

The database will be the account and game name as shown in the web address of your deltaDNA pages. Your account and game name should be separated by a full stop E.g.  demo-account.demo-game

It is recommended that you connect from Tableau using SSL as from March of 2018 we will no longer be accepting unencrypted connections to Direct Access.

 

 

Once you have entered the connection details then click Connect, Tableau will then take you to the data screen:

 

Tableau data

There will be four tables for your game: events_live and user_metrics_live, which look at the LIVE data, and events_dev  and user_metrics_dev which contain the DEV data.

You will be able to write SQL to access your data by double clicking the New Custom SQL button:

 

Tableau SQL window

 

In this example we are creating some interesting aggregates (e.g. number of missions started/completed, number of transactions, first and last mission ID) for each combination of userID and eventDate. Creating aggregates like these across some suitable dimensions (e.g. by day, level, mission, etc) is the best way to get useful results from Tableau.

Please do not drag whole tables into the worksheet, or use SELECT *  like queries. These will attempt to retrieve all data from your table, this will naturally fail if you have a large data set. Always use a LIMIT e.g SELECT * FROM events_live LIMIT 100;  or design your queries to return a limited number of rows.

In addition the default ‘wide-table’ format of event data is not very suitable for use in Tableau.

Once you have completed your query click OK.

To start using your data click Go to Worksheet.

You will now be presented with a blank Tableau worksheet with all the fields of the SQL query available to use as Dimensions or Measures