Skip to content

SQL extensions and compatibility: rewrite and move to top of Query reference#455

Merged
javier merged 2 commits into
mainfrom
jv/sql_extensions_revamp
May 27, 2026
Merged

SQL extensions and compatibility: rewrite and move to top of Query reference#455
javier merged 2 commits into
mainfrom
jv/sql_extensions_revamp

Conversation

@javier
Copy link
Copy Markdown
Collaborator

@javier javier commented May 27, 2026

Summary

Rewrites the previous `/docs/concepts/deep-dive/sql-extensions/` page to be the canonical SQL dialect reference, covering both QuestDB extensions and standard-SQL gaps. URL preserved for SEO; sidebar entry moved from Concepts > Deep Dive to the top of Query & SQL Reference where readers actually need it.

  • Page title now "SQL extensions and compatibility"; sidebar label "SQL extensions"
  • Time-series clauses: SAMPLE BY (with FILL pointer), LATEST ON, TICK including the Enterprise exchange-calendar form (XNYS)
  • Time-series joins: ASOF, LT, SPLICE, WINDOW, HORIZON, with a demoable HORIZON markout example
  • Query syntax conveniences: optional `SELECT *` and `GROUP BY`, Implicit HAVING, DECLARE variables, implicit timestamp ordering + negative LIMIT idiom
  • Storage and table extensions: designated timestamp, partitioning with link to out-of-order data, materialized views with refresh strategies and chaining, parameterized views, n-dimensional arrays, covering indices
  • PIVOT comparison vs SQL Server and PostgreSQL
  • JSON and UNNEST with both array and JSON-array (typed COLUMNS) examples
  • Lifecycle, security, and operations pointers (TTL, Storage Policy, RBAC, CHECKPOINT)
  • Function library overview, including a note that QuestDB implements only a small subset of `pg_catalog`
  • "Learn by example" section adds web console URL and `psql` command with default credentials
  • Full table of standard SQL features not supported, each with the QuestDB equivalent (DELETE, UPDATE-of-timestamp, HAVING, OFFSET, DISTINCT ON, ON CONFLICT, correlated subqueries via LATERAL, `generate_series` in SELECT, scrollable cursors, stored procedures, FKs/CHECK)
  • Full inventory of supported joins (standard + time-series)
  • Pgwire-specific caveats section

Pgwire overview page: the one-paragraph "SQL dialect differences" punt is replaced by a concise summary linking here.

javier added 2 commits May 27, 2026 14:47
Expands the existing page to cover both QuestDB additions and standard
SQL gaps in one canonical reference. New structure: time-series clauses
(SAMPLE BY with FILL, LATEST ON, TICK), time-series joins (ASOF, LT,
SPLICE, WINDOW, HORIZON), storage and table extensions (matviews with
refresh strategies and chaining, parameterized views, arrays, covering
indices, DECLARE), query conveniences, PIVOT vs SQL Server, JSON/UNNEST,
lifecycle and security pointers, function library pointers, and a table
of standard SQL features that QuestDB does not support with the QuestDB
equivalent for each.

Moves the sidebar entry from Concepts > Deep Dive to the top of Query &
SQL Reference, right after the overview, where readers actually need it.
URL stays at /docs/concepts/deep-dive/sql-extensions/ for SEO.

Replaces the one-paragraph SQL-dialect-differences punt on the pgwire
overview page with a concise summary that links here.
- ASOF JOIN example fixed to use fx_trades + core_price with real columns
- HORIZON JOIN example made demoable using the markout pattern from the
  HORIZON JOIN reference page
- TICK exchange-hours example uses the actual exchange calendar syntax
  (XNYS MIC), with a note that it is Enterprise-only
- DISTINCT ON cell clarified: LATEST ON only covers the latest-per-group
  case; other orderings use row_number() in a CTE
- FK/CHECK explanation no longer implies append-only storage; reasons
  reframed around high-throughput write paths
- DECLARE moved from storage extensions to query syntax conveniences;
  Query syntax conveniences now precede Storage and table extensions
- Added "Implicit timestamp ordering and negative LIMIT" subsection
- JSON UNNEST example added alongside the array UNNEST example
- Visualization functions blurb corrected (web console and psql, not
  Grafana)
- Meta functions blurb notes the small pg_catalog subset
- "Learn by example" expanded with web console URL and psql command,
  including the default password
@github-actions
Copy link
Copy Markdown

🚀 Build success!

Latest successful preview: https://preview-455--questdb-documentation.netlify.app/docs/

Commit SHA: 87547b2

📦 Build generates a preview & updates link on each commit.

@javier javier merged commit 5bd0a03 into main May 27, 2026
3 checks passed
@javier javier deleted the jv/sql_extensions_revamp branch May 27, 2026 15:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant