0
votes

In Tableau 10.1, I'm trying to use a view created in BigQuery using Standard SQL, however it seems that the dialect that Tableau uses is the Legacy SQL, as I keep getting the same error:

The Google BigQuery service was unable to compile the query.
Cannot reference a SQL view in a Legacy SQL query.

As per the documentation, Tableau 10.1 should use be default the Standard SQL: https://onlinehelp.tableau.com/current/pro/desktop/en-us/examples_googlebigquery.html

I have even tried to force the dialect by using a custom .tdc file, but it still doesn't work:

<connection-customization class='bigquery' enabled='true' version='10.1' >
  <vendor name='bigquery' />
  <driver name='bigquery' />
  <customizations>
    <customization name='connection-dialect' value='simba-sql' />
  </customizations>
</connection-customization>

The .tdc is loaded, I can see that in the logs (C:\Users...\Documents\My Tableau Repository\Logs\log.txt):

{"ts":"2017-01-10T21:41:20.122","pid":23988,"tid":"581c","sev":"info","req":"-","sess":"-","site":"{F3FB300D-09B3-4C60-94E0-EAF83FA07153}","user":"-","k":"msg","v":"Found TDC 'C:\\Users\\...\\Documents\\My Tableau Repository\\Datasources\\bigquery.tdc'."}

What's wrong?

2
I can't find any documentation on supported connection-dialect values. Are you sure that simba-sql is right? You may just want to contact Tableau support to see what they suggest. - Elliott Brossard

2 Answers

0
votes

You may enable Standard SQL in BigQuery, as described in the BigQuery SQL Reference document, or use Legacy SQL, to fit your Tableau dialect preferences.

0
votes

You're right, you can't just add #StandardSQL decorator.

You'll need to update your version of Tableau. I tried on 10.1 and wasn't able to use StandardSQL and then I installed 10.1.17 and I was able to use StandardSQL.

You'll know quite quickly whether the version of Tableau you installed supports StandardSQL because there is a 'Use Legacy SQL' checkbox, which of course you want unchecked.