ToolJet/docs/versioned_docs/version-2.68.0/tutorial/building-queries.md
Aman Regu bdfe3270e2
[docs]: v2.68.0-Beta (#10755)
* docs: jira

* docs: formatting + Client Credentials grant type

* docs: connection string pgsql

* docs: parameterized queries mysql

* docs: parameterized queries in PostgreSQL

* docs: update mysql example

* docs: TJDB sql editor

* docs: add metadata to REST API

* docs: add, update  postgresql media

* docs: add metadata to graphql

* docs: update parameterized queries

* docs: add parameterized queries for mssql

* docs: add SSL Cert to mysql

* docs: TJDB SQL restricted commands

* docs: update JIRA token location

* docs: update delete issue example

* docs: update find user by query example

* docs: remove session id from get assignable users

* docs: use correct image for get issues for board

* docs: update create issue example

* docs: update delete issue media

* docs: update assignable users media

* docs: update examples

* docs: update key desc

* docs: v2.68.0-Beta
2024-09-13 19:23:19 +05:30

1.7 KiB

id title
building-queries Building Queries

Building Queries

Query Editor lives at the bottom of the page. We will now build a query for the PostgreSQL datasource that we connected in the previous step.

:::tip You can click on the 'enlarge' icon to enlarge query editor pane. :::

  • Click on the + icon of the query editor to create a new query.
  • Select the PostgreSQL datasource created in previous step.
  • Copy the query given below and paste on the query area.
  • Select SQL mode
SELECT * FROM customers;
query

Query results can be previewed by clicking the preview button. Previewing queries will not alter the state of the app.

preview

Advanced options

advanced options

Run query on page load

If this option is enabled, the query will be run when the app is loaded for the first time. The queries can have more than one trigger, ie the same query can later be triggered again using a button's click event or table's row selected event or any other events.

Request confirmation before running query

Enable this option to show a prompt to confirm the action before a query is run. The confirmation prompt will look like this:

confirm

Show notification on success

Enable this option to show a custom message on query completion. Duration of the notification can also be set.