Skip to content

Creating a view from an SQL script

Once you have a SELECT query working the way you want on the SQL tab, you can save it as a view so you can reuse it by name.

To turn a script into a view:

  1. Select the whole script and copy it to the clipboard (Ctrl+A, then Ctrl+C).
  2. Choose Object → New View from the main menu, or New View from the tree panel's pop-up menu.
  3. Paste the script into the View Body box.
  4. Enter a name for the view.
  5. To create a temporary view, tick Temporary view.
  6. Click Apply.

Tip

Make sure every column your query returns has a clear name (use AS aliases for computed columns) before saving it as a view — see the note in Creating a view and Known Issues.

See also: Creating a view · Generating views using the Query Builder