3 Replies Latest reply on Oct 17, 2017 11:55 AM by Hari Ankem

    Initial SQL volatile tables error - "Data definition not valid unless solitary"

    Adam Adam

      Hi,

       

      I have an NDW query which runs without issue in SQL Assistant but produces an error when Tableau attempts to run it as an Initial SQL query. The query is broken into multiple steps because I was running out of spool space with them as CTEs.

       

      I'm using Tableau 9.3.5 and Teradata ODBC drivers 15.10.

       

      The query is structured like this:

      CREATE VOLATILE TABLE VT_SOURCE AS

      (

      SELECT THINGS

      FROM STUFF

      ) WITH DATA NO PRIMARY INDEX ON COMMIT PRESERVE ROWS;

       

      CREATE VOLATILE TABLE VT_SOURCE2 AS

      (

      SELECT THINGS

      FROM VT_SOURCE

      JOIN DATE_STUFF

      ) WITH DATA NO PRIMARY INDEX ON COMMIT PRESERVE ROWS;

       

      CREATE VOLATILE TABLE VT_RESULT AS

      (

      SELECT THINGS

      FROM VT_SOURCE2

      JOIN OTHER_STUFF

      ) WITH DATA NO PRIMARY INDEX ON COMMIT PRESERVE ROWS;

       

      INSERT INTO VT_RESULT

      SELECT THINGS

      FROM VT_SOURCE2

      JOIN EVEN_MORE_STUFF;

      --with 8 more INSERT statements

       

      The entire statement will not run and produces this error message:

      • [Teradata][ODBC Teradata Driver][Teradata Database] Data definition not valid unless solitary.
      • Initial SQL Error. Check that the syntax is correct and that you have access privileges to the requested database.

       

       

      The first statement (VT_SOURCE) will run without issue.

       

      The first two statements (VT_SOURCE and VT_SOURCE2) will run together without issue.

       

      The first three statements (VT_SOURCE, VT_SOURCE2, and VT_RESULT) run together will produce the above error 9 out of 10 times.

       

      I have searched the internet and found only 2 suggestions to remove something from ODBC.ini (the something doesn't exist in my ODBC.ini) and to remove the very last semicolon (this seems to have no effect).

       

      I have replicated this error on multiple machines with multiple users using multiple Teradata ODBC driver versions, and have even freshly installed Teradata 15.10 drivers to no effect.

       

      anyone knows Where is this error coming from and how do I prevent it please?

       

      Thank you