Play with details in the a personalized SQL inquire

Play with details in the a personalized SQL inquire

Play with details in the a personalized SQL inquire

You need another custom SQL inquire locate an excellent count on exactly how many commands and you may manage a left register on the Orders and Providers tables:

Problems whenever copy articles try referenced

In the event the individualized SQL ask recommendations content articles, you could get errors of trying to make use of among columns on the data into the Tableau. This may happen even if the ask holds true. Eg, check out the following query:

The fresh ask is true, although bien au_id profession is confusing as the in this situation it can be obtained for the both the “authors” dining table plus the “titleauthor” table. Tableau often connect to new query however you will score an error whenever you try to use the bien au_id field. It is because Tableau cannot learn and this dining table you are referring so you’re able to.

Note: It’s a just behavior to help you determine column aliases with an enthusiastic Just like the condition whenever possible into the a personalized SQL Inquire. For the reason that for every single database features its own laws whether or not it concerns automatically promoting a column label just in case an enthusiastic alias try perhaps not used.

Edit a custom SQL inquire

  1. Into the repository webpage, from the canvas, double-click on the personalized SQL ask about logical level.
  2. Hover over the personalized SQL dining table about physical covering up to the fresh new arrow displays.
  3. Click the arrow after which discover Modify Individualized SQL Query .
  4. On the dialogue box, revise new customized SQL inquire.

After you drag a personalized SQL ask into the logical covering of your fabric, Tableau gets it a standard term: Individualized SQL Ask, Customized SQL Query1, and so on. You could potentially replace the standard label to something a whole lot more meaningful.

Towards the databases web page, regarding the analytical layer of your material, get the get rid of-down arrow on the personalized SQL inquire desk and select Rename .

You can utilize variables into the a personalized SQL query statement to help you change a steady well worth that have an active well worth. You’ll be able to posting the fresh parameter throughout the workbook to change the connection. Like, you can interact with a custom made SQL ask that provides internet guests studies to possess a certain page that’s specified of the good pageID. Instead of using a stable worthy of toward pageID well worth inside the fresh new SQL query, you could enter a parameter. After that immediately after completing the relationship, you might tell you a parameter handle regarding the workbook. Use the factor manage to change out the pageID and you can eliminate for the data each web page interesting without the need to revise or backup the connection.

In Tableau Pc, you possibly can make a factor straight https://datingranking.net/escort-directory/joliet from the newest Customized SQL dialogue package or have fun with people parameters that will be the main workbook. For those who perform another parameter, it becomes designed for use in this new workbook as with any almost every other factor. Find Manage Variables to learn more.

For websites authoring (inside Tableau On the web or Tableau Host), you can utilize a current parameter composed away from Tableau Desktop computer. You simply can’t perform a unique factor when you look at the net authoring.

  1. Towards the repository webpage, from the material, hover along the table till the revise symbol screens, and click the newest revise button.
  2. At the end of your dialogue package, simply click Submit Factor .
  3. Pick a steady well worth regarding the SQL statement right after which, regarding the Insert Parameter lose-off diet plan discover parameter we want to fool around with alternatively. For those who have not authored a factor yet ,, find Perform another factor . Stick to the advice for the Carry out Variables to produce a parameter.

In the analogy below, this new individualized SQL query productivity all of the instructions that are marked just like the Immediate priority. Throughout the individualized SQL declaration, your order priority is the constant worth. If you’d like to change the link with see the Higher top priority requests, you would need to change the content source.

Share this post