Skip to main content

How to run SQL queries within DBView

How to run SELECT queries against the database and work with your results and query history.

Written by Erica

The SQL Display tab lets you run simple queries against the database using Structured Query Language (SQL). When you enter a SQL statement into the top-right editor pane and run it, the results are displayed in the table below under the Results tab.

  • Enter the SQL statement into the editor pane. Only SELECT statements can be run.

🤓 Tip: Press CTRL + Space to display a list of functions and their parameters available for selection. Type-ahead functionality enables you to filter the list. Press Tab or Enter to accept a suggestion.

  • Click Load SQL to open an explorer window, where you can find and select a saved SQL statement.

  • Click Save SQL to open an explorer window, where you can select the folder in which to save the SQL.

  • Click Insert SELECT Statement to generate a basic select statement for the selected table. The button name then updates to Insert Table Name, enabling you to insert the full table name for the selected table.

  • Click Execute SQL to run the query. If the SQL execution is successful, the results are displayed in the grid below the editor.

  • Click Export to export all or selected results to an XLSX or comma-separated values (CSV) format. See the Export data to XLSX or CSV article.

  • Click Bookmark to export all or selected results to a new bookmark, or to append to an existing bookmark. The Bookmark dialog is displayed.

  • Select the History tab to view previously run queries. Clicking a previously run query populates the SQL editor and the results grid. The list of SQL statements is valid only for the current session.

📌 Note: When creating a SQL query, use the prefix DBA when calling a table. For example, LU_INTERVENTION will not load any data, but DBA.LU_INTERVENTION will.

Did this answer your question?