Skip to content

Latest commit

 

History

History
217 lines (201 loc) · 32.2 KB

sql-conformance.md

File metadata and controls

217 lines (201 loc) · 32.2 KB

SQL conformance

This is the SQL half of the conformance scoring decided in ADR-0035. It publishes what Ravel's SQL surface supports, what it deliberately rejects, and what (if anything) is neither -- scored over the surface Ravel actually claims, not over all of DataFusion SQL (ADR-0035 Rejected Alternative A).

Ravel's SQL surface is a deliberately narrow allowlist, not general-purpose SQL: a six-aggregate set and read-only SELECT only (ADR-0033, ADR-0022). Scoring against all of DataFusion SQL would be meaningless (a tiny fixed percentage that never moves); scoring against only the declared surface would read ~100% by construction. The three-state scheme below is the resolution: enumerate the claimed surface, score over the part with a deliberate verified position, and keep any unresolved construct visible as an actionable miss.

The samples table

The samples table exposes exactly four columns -- ts, value, series_id, and labels -- where value is a single Float64 (crates/ravel-sql/src/schema.rs, public_fields). It has no column that can represent a native histogram. Native-histogram samples are excluded from the samples table entirely: a histogram sample carries no scalar float value, so it is never materialized as a row and no query can observe it. SELECT count(*) FROM samples, and every other count or aggregation over the table, therefore undercount on tenants that ingest histograms -- the histogram samples are absent, not present with a zero or null value. This is a property of the table shape, not of any construct in the conformance table below, so it holds for every row that reads samples.

The undercount is not silent. A statement whose scan matched histogram-kind series and excluded them returns its rows with a top-level warnings array saying so, in the same envelope field and with the same omit-when-empty rule the PromQL endpoints use. A tenant with no histogram data gets no warning, so the signal means something when it appears. Two surfaces cannot carry it: an Arrow IPC response is a bare columnar payload with no envelope, and a statement executed through the distributed scan lane counts nothing, because the scan that excluded the series ran on a worker whose counters do not cross back.

The three states

  1. Supported and covered -- implemented, with a passing test proving it. These constructs are exercised by the two-layer differential gate (crates/ravel-sql/tests/pipeline.rs and crates/ravel-sql/tests/differential.rs) against an independent reference, and re-confirmed to execute by the conformance suite (crates/ravel-sql/tests/conformance.rs).
  2. Intentionally rejected -- refused with a typed error, never a panic and never silently-wrong data. This is the allowlist working as designed: the aggregates outside the admitted six, every write/DDL statement, and a query spanning both signal tables. The conformance suite asserts each returns its declared typed error.
  3. Unclassified / broken -- implemented but untested, or claimed-supported but actually wrong. No construct is declared into this state; a row lands here only when its live behavior contradicts its declaration, which fails the suite. A regression therefore shows up as a diff in this table in the same change that caused it.

The score is states 1 and 2 combined, over the total enumerated surface. A row in state 3 lowers it; an out-of-scope construct Ravel rejects cleanly is state 2 and stays conformant.

Score

  • Supported and covered: 59
  • Intentionally rejected: 70
  • Unclassified / broken: 0
  • Conformance: 129 / 129 = 100.0%

Conformance table

Category Construct Example State Evidence Rationale
Aggregate any_value SELECT any_value(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate approx_distinct SELECT approx_distinct(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate approx_median SELECT approx_median(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate approx_percentile_cont SELECT approx_percentile_cont(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate approx_percentile_cont_with_weight SELECT approx_percentile_cont_with_weight(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate array_agg SELECT array_agg(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate avg SELECT avg(value) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute admitted aggregate (ADR-0022); exact against the differential gate
Aggregate bit_and SELECT bit_and(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate bit_or SELECT bit_or(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate bit_xor SELECT bit_xor(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate bool_and SELECT bool_and(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate bool_or SELECT bool_or(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate corr SELECT corr(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate count SELECT count(value) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute admitted aggregate (ADR-0022); exact against the differential gate
Aggregate covar SELECT covar(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate covar_pop SELECT covar_pop(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate covar_samp SELECT covar_samp(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate first_value SELECT first_value(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate grouping SELECT grouping(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate last_value SELECT last_value(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate max SELECT max(value) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute admitted aggregate (ADR-0022); exact against the differential gate
Aggregate mean SELECT mean(value) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute admitted aggregate (ADR-0022); exact against the differential gate
Aggregate median SELECT median(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate min SELECT min(value) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute admitted aggregate (ADR-0022); exact against the differential gate
Aggregate nth_value SELECT nth_value(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate percentile_cont SELECT percentile_cont(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate quantile_cont SELECT quantile_cont(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate regr_avgx SELECT regr_avgx(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate regr_avgy SELECT regr_avgy(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate regr_count SELECT regr_count(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate regr_intercept SELECT regr_intercept(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate regr_r2 SELECT regr_r2(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate regr_slope SELECT regr_slope(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate regr_sxx SELECT regr_sxx(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate regr_sxy SELECT regr_sxy(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate regr_syy SELECT regr_syy(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate stddev SELECT stddev(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate stddev_pop SELECT stddev_pop(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate stddev_samp SELECT stddev_samp(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate string_agg SELECT string_agg(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate sum SELECT sum(value) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute admitted aggregate (ADR-0022); exact against the differential gate
Aggregate var SELECT var(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate var_pop SELECT var_pop(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate var_population SELECT var_population(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate var_samp SELECT var_samp(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Aggregate var_sample SELECT var_sample(value) FROM samples Intentionally rejected ValidationError::ExcludedAggregate outside the six-aggregate allowlist (ADR-0022 decision 2)
Clause / operator CASE SELECT CASE WHEN value > 0 THEN 1 ELSE 0 END FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator DATE_TRUNC SELECT date_trunc('hour', ts) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator EXTRACT(minute FROM ...) SELECT EXTRACT(minute FROM ts) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator Filter (WHERE) SELECT ts, value FROM samples WHERE value > 0 ORDER BY series_id, ts Supported and covered tests/conformance.rs::supported_constructs_execute covered by the two-layer differential gate (tests/differential.rs)
Clause / operator GROUP BY SELECT series_id, count(value) FROM samples GROUP BY series_id ORDER BY series_id Supported and covered tests/conformance.rs::supported_constructs_execute covered by the two-layer differential gate (tests/differential.rs)
Clause / operator GROUP BY ordinal SELECT series_id, count(value) FROM samples GROUP BY 1 ORDER BY series_id Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator HAVING SELECT series_id, count(value) FROM samples GROUP BY series_id HAVING count(value) > 2 Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator IN list SELECT value FROM samples WHERE value IN (1, 2) Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator LIKE SELECT count(*) FROM logs WHERE body LIKE '%record 1%' Supported and covered tests/conformance.rs::supported_constructs_execute substring pattern match via the Ravel like UDF
Clause / operator LIMIT SELECT ts, value FROM samples ORDER BY series_id, ts LIMIT 1 Supported and covered tests/conformance.rs::supported_constructs_execute covered by the two-layer differential gate (tests/differential.rs)
Clause / operator OFFSET SELECT value FROM samples ORDER BY value OFFSET 1 Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator ORDER BY SELECT ts, value FROM samples ORDER BY ts Supported and covered tests/conformance.rs::supported_constructs_execute covered by the two-layer differential gate (tests/differential.rs)
Clause / operator OVERLAY(x PLACING y FROM n) SELECT OVERLAY('abc' PLACING 'x' FROM 2) Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator POSITION(x IN y) SELECT POSITION('a' IN 'ab') Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator Projection SELECT ts, value FROM samples ORDER BY series_id, ts Supported and covered tests/conformance.rs::supported_constructs_execute covered by the two-layer differential gate (tests/differential.rs)
Clause / operator REGEXP_REPLACE backreference SELECT regexp_replace('ab', '(a)(b)', '\2\1') FROM samples LIMIT 1 Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator STRUCT(...) literal SELECT STRUCT(1, 2)['c1'] Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator SUBSTRING(x FROM y FOR z) SELECT SUBSTRING('abcdef' FROM 2 FOR 3) Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator SUBSTRING(x FROM y) SELECT SUBSTRING('abcdef' FROM 3) Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator attrs['k'] map subscript SELECT count(*) FROM logs WHERE attrs['dur'] = '10' Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator count() SELECT count() FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator count(*) OVER () SELECT max(c) FROM (SELECT count(*) OVER () AS c FROM samples) Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator count(DISTINCT) SELECT count(DISTINCT series_id) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator date_part(minute) SELECT date_part('minute', ts) FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute analytical clause/operator over typed columns (ADR-0090 decision 8)
Clause / operator declared i64 typed aggregate SELECT sum(dur) FROM logs Supported and covered tests/conformance.rs::supported_constructs_execute typed predicate/aggregate over a typed attribute column (ADR-0090)
Clause / operator declared i64 typed comparison SELECT ts FROM logs WHERE dur >= 20 Supported and covered tests/conformance.rs::supported_constructs_execute typed predicate/aggregate over a typed attribute column (ADR-0090)
Clause / operator named_struct(...)['k'] subscript SELECT named_struct('a', 1, 'b', 2)['b'] Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator struct field s.a SELECT s.a FROM (SELECT named_struct('a', 2, 'b', 1) AS s) Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator trace_id = '<32-hex>' SELECT count(*) FROM spans WHERE trace_id = '01234567890123456789012345678901' Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator unquoted substr(x, y, z) SELECT substr('abcdef', 2, 3) Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator unquoted substring(x, y, z) SELECT substring('abcdef', 2, 3) Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Clause / operator {'k': v} literal SELECT {'a': 1, 'b': 2}['b'] Supported and covered tests/conformance.rs::supported_constructs_execute syntax a registered expression planner rewrites (ADR-0097)
Scalar function abs SELECT abs(-3.5) FROM samples LIMIT 1 Supported and covered tests/conformance.rs::supported_constructs_execute math family representative: abs(-3.5) = 3.5
Scalar function current_date SELECT current_date FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function current_time SELECT current_time FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function current_timestamp SELECT current_timestamp FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function encode SELECT encode('a', 'hex') FROM samples LIMIT 1 Supported and covered tests/conformance.rs::supported_constructs_execute encoding family representative: hex of the byte 0x61 = '61'
Scalar function file_row_index SELECT file_row_index() FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function has_word SELECT count(*) FROM logs WHERE has_word(body, '1') Supported and covered tests/conformance.rs::supported_constructs_execute Ravel per-table scalar UDF, individually attested (ADR-0097 decision 8)
Scalar function input_file_name SELECT input_file_name() FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function label SELECT label(labels, '__name__') FROM samples WHERE value = 3.0 Supported and covered tests/conformance.rs::supported_constructs_execute Ravel per-table scalar UDF, individually attested (ADR-0097 decision 8)
Scalar function label_match SELECT count(*) FROM samples WHERE label_match(labels, '__name__', 'b') Supported and covered tests/conformance.rs::supported_constructs_execute Ravel per-table scalar UDF, individually attested (ADR-0097 decision 8)
Scalar function length SELECT length('résumé') FROM samples LIMIT 1 Supported and covered tests/conformance.rs::supported_constructs_execute character count, not byte count: 'résumé' is 6 characters but 7 bytes (the 'é's are two-byte UTF-8)
Scalar function now SELECT now() FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function rand SELECT rand() FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function random SELECT random() FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function regexp_replace SELECT regexp_replace('foo123bar', '[0-9]+', 'X') FROM samples LIMIT 1 Supported and covered tests/conformance.rs::supported_constructs_execute regex family representative: first-match replace of the digit run = 'fooXbar'
Scalar function reverse SELECT reverse('résumé') FROM samples LIMIT 1 Supported and covered tests/conformance.rs::supported_constructs_execute unicode family representative: reverse('résumé') = 'émusér' (character-wise, not byte-wise)
Scalar function to_char SELECT to_char(make_date(2024, 7, 15), '%Y-%m-%d') FROM samples LIMIT 1 Supported and covered tests/conformance.rs::supported_constructs_execute datetime family representative: to_char over a tz-free Date32 = '2024-07-15'
Scalar function today SELECT today() FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function upper SELECT upper('ab') FROM samples LIMIT 1 Supported and covered tests/conformance.rs::supported_constructs_execute string family representative: upper('ab') = 'AB'
Scalar function uuid SELECT uuid() FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Scalar function version SELECT version() FROM samples Intentionally rejected ValidationError::ExcludedScalar nondeterministic or environment-reading; unattestable by the differential oracle (ADR-0097 decision 4)
Window function cume_dist SELECT max(c) FROM (SELECT cume_dist() OVER (ORDER BY value) AS c FROM samples) Supported and covered tests/conformance.rs::supported_constructs_execute admitted native window function (ADR-0097 decision 6)
Window function dense_rank SELECT max(d) FROM (SELECT dense_rank() OVER (ORDER BY value) AS d FROM samples) Supported and covered tests/conformance.rs::supported_constructs_execute admitted native window function (ADR-0097 decision 6)
Window function first_value SELECT first_value(value) OVER (ORDER BY ts) FROM samples Intentionally rejected ValidationError::ExcludedWindow excluded window function; bare spelling is a separate ExcludedAggregate row (ADR-0097 decision 6)
Window function lag SELECT count(p) FROM (SELECT lag(value) OVER (ORDER BY value) AS p FROM samples) Supported and covered tests/conformance.rs::supported_constructs_execute admitted native window function (ADR-0097 decision 6)
Window function last_value SELECT last_value(value) OVER (ORDER BY ts) FROM samples Intentionally rejected ValidationError::ExcludedWindow excluded window function; bare spelling is a separate ExcludedAggregate row (ADR-0097 decision 6)
Window function lead SELECT count(nx) FROM (SELECT lead(value) OVER (ORDER BY value) AS nx FROM samples) Supported and covered tests/conformance.rs::supported_constructs_execute admitted native window function (ADR-0097 decision 6)
Window function nth_value SELECT nth_value(value, 2) OVER (ORDER BY ts) FROM samples Intentionally rejected ValidationError::ExcludedWindow excluded window function; bare spelling is a separate ExcludedAggregate row (ADR-0097 decision 6)
Window function ntile SELECT max(n) FROM (SELECT ntile(2) OVER (ORDER BY value) AS n FROM samples) Supported and covered tests/conformance.rs::supported_constructs_execute admitted native window function (ADR-0097 decision 6)
Window function percent_rank SELECT max(pr) FROM (SELECT percent_rank() OVER (ORDER BY value) AS pr FROM samples) Supported and covered tests/conformance.rs::supported_constructs_execute admitted native window function (ADR-0097 decision 6)
Window function rank SELECT max(r) FROM (SELECT rank() OVER (ORDER BY value) AS r FROM samples) Supported and covered tests/conformance.rs::supported_constructs_execute admitted native window function (ADR-0097 decision 6)
Window function row_number SELECT max(rn) FROM (SELECT row_number() OVER (ORDER BY value) AS rn FROM samples) Supported and covered tests/conformance.rs::supported_constructs_execute admitted native window function (ADR-0097 decision 6)
Window frame avg (moving frame) SELECT avg(value) OVER (ORDER BY ts ROWS BETWEEN 2 PRECEDING AND CURRENT ROW) FROM samples Intentionally rejected SqlError::Execution moving-frame avg has no retract_batch, so DataFusion refuses it (ADR-0097 decision 5)
Write / DDL statement ALTER TABLE ALTER TABLE samples ADD COLUMN x INT Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement COPY COPY (SELECT 1) TO 's3://evil/out.parquet' Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement CREATE EXTERNAL TABLE CREATE EXTERNAL TABLE t (a INT) STORED AS PARQUET LOCATION '/tmp/x' Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement CREATE SCHEMA CREATE SCHEMA s Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement CREATE TABLE CREATE TABLE t (a INT) Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement CREATE VIEW CREATE VIEW v AS SELECT 1 Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement DELETE DELETE FROM samples Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement DROP DROP TABLE samples Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement EXPLAIN EXPLAIN SELECT 1 Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement INSERT INSERT INTO samples VALUES (1, 2.0) Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement PREPARE PREPARE p AS SELECT 1 Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement SET SET datafusion.execution.batch_size = 1 Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement Transaction control BEGIN TRANSACTION Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement UPDATE UPDATE samples SET value = 1 Intentionally rejected ValidationError::NotReadOnly read-only endpoint; refused before planning (crate::validate)
Write / DDL statement Write nested in a query body WITH c AS (SELECT 1) INSERT INTO samples VALUES (1, 2.0) Intentionally rejected ValidationError::WriteInQuery read-only endpoint; refused before planning (crate::validate)
Table dispatch both tables (cross-signal) SELECT samples.value, logs.body FROM samples JOIN logs ON CAST(logs.ts AS BIGINT) = CAST(samples.ts AS BIGINT) + 999 Supported and covered tests/conformance.rs::supported_constructs_execute one snapshot per signal, joined on the coordinator (ADR-2904)
Table dispatch logs -> Signal::Logs SELECT ts, body FROM logs Supported and covered tests/conformance.rs::supported_constructs_execute logs dispatch via referenced_base_tables (ADR-0033)
Table dispatch samples -> Signal::Metrics SELECT ts, value FROM samples Supported and covered tests/conformance.rs::supported_constructs_execute metrics dispatch via referenced_base_tables (ADR-0033)