KNOWLEDGE BASE

Query Running Indefinitely When Adding Top N, IN/OUT Set to a View that Uses Custom SQL with Oracle


Published: 30 Nov 2016
Last Modified Date: 01 Mar 2017

Issue

When connected to Oracle using custom SQL, adding a Top N, IN/OUT set to the view would result in a query that ran indefinitely.

Environment

  • Tableau Desktop 9.2.0 and later
  • Oracle

Resolution

Option 1

Upgrade to Tableau Desktop 10.2. For more information, see Upgrading Tableau Desktop.

Option 2

Add a Top N set to the view as discrete members instead of IN/OUT (right click and drag the set into the view).
 

Cause

The query generated in the latest versions will add the following SQL causing this behavior: OR (("Custom SQL Query"."Order ID" IS NULL) AND ("t0"."Order ID" IS NULL))

Additional Information

This behavior is related to a known issue (ID: 591041) that has been fixed in a recent version of Tableau Desktop. 
Did this article resolve the issue?