Using the Query Builder
Last updated
Was this helpful?
Last updated
Was this helpful?
Airbook's Query Builder allows you to retrieve and manipulate data without writing SQL. Simply select your desired options, and the Query Builder will generate an SQL-equivalent output for you.
To get started type / and pick Query Builder from the dropdown.
Click the Edit button to open the Query Builder menu.
The menu consists of:
Left Panel: Configuration options for generating your query.
Right Panel: A preview of the table output.
Click + Select Table in the Left Panel.
Choose:
Datasource
Dataset
Table
Select columns to include:
Choose all columns or specific columns.
Create aggregate columns if needed.
Click Add Columns to apply changes.
You can join another table only if it belongs to the same datasource.
Select columns for the second table after identifying a common column (join key).
Types of Joins:
Left Join: Returns all records from the left table and matching records from the right table.
Right Join: Returns all records from the right table and matching records from the left table.
Inner Join: Returns only records with matching values in both tables.
Outer Join: Returns all records from both tables, filling missing values with NULL.
Create new fields by applying calculations to existing columns.
Name Your Column (e.g., profit
).
Select Aggregation Method (if applicable).
Write Your Formula (e.g., calculating profit):
Table1.selling_price - Table1.cost
Click Add to save.
Your new column will now appear in the query results.
Select a column to filter.
Choose an operator (e.g., =
, >
, <
).
Enter a value.
Add multiple conditions if needed.
Click Apply to filter the results.
Choose a column to sort by.
Select the sort order: Ascending (A → Z) or Descending (Z → A).
Specify the maximum number of rows to display.
Click Preview to check the results before running the query.
Click Run to execute and save your changes.
By following these steps, you can build and modify queries efficiently without writing SQL!