1 Reply Latest reply on Oct 1, 2013 2:22 PM by Tj Claridge

    Why doesn't my RAWSQL calculation work?

    Tj Claridge

      Hey All,

       

      First of all I'm not heavily experienced in SQL queries but in one workbook it works great but another it fails saying it can't find the table name.

       

      Microsoft JET database error 0x80040E37: The Microsoft Jet database engine cannot find the input table or query 'Tableau$'.  Make sure it exists and that its name is spelled correctly.

       

      I'm using an excel file created with Excel 2010 and Version8 of Tableau which is connected to the source live (no extract).

       

      Steps:

      1. Updated my excel sheet with new data.

      2. Opened my existing dashboard within Tableau and refreshed (new data populated)

      2a. Tableau connection is a custom SQL but mainly only to remove some of the columns it pulls in. It isn't doing anything fancy.

      2b. Last line in the SQL query is "FROM [Tableau$]" === The name of the Excel tab from which I'm pulling data.

      3. Created a RAWSQLAGG_INT( ) calculation

      3a. RAWSQLAGG_INT('Select sum([specialcounts]) From [Tableau$]')

      4. Drag it out to text to view

      5. Error

       

      Troubleshooting steps:

      1. Changed ' to " (double quotes) and played with the options a bit (%1 ect...) == still an error

      2. Opened new Tableau workbook - connected to same data source - used same custom SQL connection query - Used same rawsql calculation in step 3a.... Works like a charm. Destroyed workbook (don't need extras around).

      3. Saved and closed original workbook, reopened workbook, tested == Failed again <-- repeated a few times with no luck.

       

      So this appears to be tied directly to my single workbook but I don't see how it can be failing given the custom SQL connection query is using the same table name to establish the connection and pull in the data. Anyone have some ideas on how to fix this?

       

      Thanks in advance,
      TJ

        • 1. Re: Why doesn't my RAWSQL calculation work?
          Tj Claridge

          I have found the issue.

           

          It has something to do with context filters. I was using a context filter to create a range of exclusion dates (testing period) that appeared to cause this problem. Once I started removing the filters I found this one to resolve everything. I was applying it as a global filter so all created views using that source automatically populated the filter.

           

          So if you are having some issues with an SQL query check your filters.

          1 of 1 people found this helpful