Fool around with parameters for the a customized SQL inquire

Fool around with parameters for the a customized SQL inquire

You need to use another customized SQL ask to track down an excellent rely on what amount of sales and carry out a left sign-up toward Sales and you may Vendors tables:

Errors whenever duplicate articles are referenced

Should your customized SQL query recommendations duplicate columns, you will get errors of trying to utilize one of the columns on your data for the Tableau. This will takes place even if the query is valid. Such as, look at the after the query:

New ask is valid, although au_id career try not clear due to the fact in such a case it can be acquired in the both the “authors” table while the “titleauthor” dining table. Tableau have a tendency to get in touch with this new inquire but you’ll score an mistake whenever you just be sure to make http://datingranking.net/escort-directory/gilbert use of the bien au_id profession. For the reason that Tableau will not understand and that desk you’re it comes down to.

Note: It’s a sole behavior so you’re able to explain column aliases having a keen Once the clause as much as possible within the a personalized SQL Inquire. This is because for every single database has its own laws whether it comes to automatically generating a line identity if in case a keen alias try not used.

Modify a custom made SQL ask

  1. With the databases page, from the material, double-click on the customized SQL query on logical covering.
  2. Hover across the individualized SQL table from the actual coating until the fresh arrow screens.
  3. Click the arrow then look for Revise Individualized SQL Ask .
  4. On the dialog container, revise brand new customized SQL inquire.

Once you drag a personalized SQL ask to your analytical level of the canvas, Tableau provides it a standard label: Personalized SQL Ask, Customized SQL Query1, etc. You could potentially change the default term so you can some thing alot more meaningful.

On databases webpage, in the logical covering of your canvas, discover shed-off arrow regarding customized SQL ask desk and pick Rename .

You can make use of details from inside the a custom made SQL ask statement so you can change a reliable really worth which have a dynamic value. Then you’re able to posting the parameter about workbook to modify the partnership. Like, you may also get in touch with a custom made SQL ask giving online travelers investigation for a certain page which is specified because of the a great pageID. Unlike playing with a steady worthy of towards pageID value in the brand new SQL inquire, you can type a parameter. Up coming after finishing the partnership, you might inform you a factor handle in the workbook. Use the parameter control to alter from pageID and you will eliminate inside research for every single page of interest without having to modify otherwise content the connection.

During the Tableau Desktop, you possibly can make a parameter directly from the Customized SQL dialog box or explore one variables that are an element of the workbook. For many who would a new factor, it will become readily available for include in the workbook just like any almost every other parameter. Pick Would Variables to learn more.

Having online authoring (inside the Tableau Online or Tableau Server), you need an existing factor wrote out-of Tableau Desktop. You cannot manage a different factor inside net authoring.

  1. On data source page, from the material, hover across the desk before change symbol screens, and then click brand new modify switch.
  2. At the bottom of one’s dialog container, mouse click Insert Parameter .
  3. Discover a steady really worth regarding SQL report following, regarding Submit Parameter miss-off selection select the factor we would like to explore alternatively. When you have maybe not authored a parameter but really, come across Create a different factor . Proceed with the rules in Carry out Details to manufacture a parameter.

On example below, the individualized SQL inquire yields most of the commands that are marked while the Urgent concern. About customized SQL report, the transaction top priority is the ongoing worthy of. If you want to replace the connection to see the Highest consideration commands, you would have to revise the info resource.

Comments are closed.