DatavineDatavine/Docs
Querying Data

SQL Editor

A multi-tab SQL editor with syntax highlighting, dataset browser, query history, and direct BigQuery execution.

Editor overview

The SQL Editor is split into three panels: a dataset/table browser on the left, the editor in the center, and results below.

Left panel
Browse datasets and tables. Click a table to see its schema.
Editor panel
Multi-tab editor with syntax highlighting, auto-complete, and line numbers.
Results panel
Query results with row count, execution time, bytes scanned, and export options.

Keyboard shortcuts

Cmd/Ctrl + EnterRun entire query
Cmd/Ctrl + Shift + EnterRun selected text only
Cmd/Ctrl + SSave query
Cmd/Ctrl + /Toggle comment
Cmd/Ctrl + KOpen command palette

Execution stats

After each query runs, the status bar shows:

  • Rows — number of rows returned
  • Duration — total execution time
  • Bytes scanned — data processed (affects cost)
  • Cache hit — whether results came from cache (free)

Example queries

sql
-- Basic table sample
SELECT * FROM `project.dataset.table` LIMIT 100;

-- Count rows by category
SELECT category, COUNT(*) as count
FROM `project.dataset.orders`
GROUP BY category
ORDER BY count DESC;

-- Time-filtered query (partition pruning)
SELECT *
FROM `project.dataset.events`
WHERE DATE(created_at) >= DATE_SUB(CURRENT_DATE(), INTERVAL 7 DAY);
Use partition filters on partitioned tables to dramatically reduce bytes scanned and cost.