Operator
Search…
Queries
SQL queries are the interface for working with data in Operator, allowing you to write powerful queries that automate complicated data tasks for monthly reporting, financial planning, and more.

Selecting sources

In the previous section, we saw how our sources are listed in the left sidebar. We can use those in our SQL query by using SELECT statements. For example, we can see all our Quickbooks Online expenses and information on their associated accounts by selecting qbo.purchase, qbo.account and joining the two.
SQL syntax varies depending on with database you are trying to query, so make sure you're using the correct syntax for the database source you have selected. Applications sources will use PostgreSQL syntax.

Updating your sources

If at any point you want to make sure you have the latest state of your sources, you can click the refresh icon in the left sidebar. This will re-introspect your sources.
<Image of refreshing schemas>

Previewing a query

Now let's try running a more complicated query.
To run this query and see the results, click "Preview" and the results will show up below. Each time you update your query, you have to click the Preview button in order to see updated results.
Clicking "Preview" will save your query, so make sure to do it often. You can also undo/redo (CTRL+Z/CTRL+Y) inside the query editor.
Once you are satisfied with the results of your updated query, it's time to set a destination for the outputs 👉
Last modified 7mo ago