6e42a118a3
The C5a design: a stratified, recursive WHERE-expression grammar (AND/OR/NOT, comparisons, LIKE, IS NULL, IN, BETWEEN) for update / delete / show-data filters; show data gains optional `where` and `limit`. Adds the `Subgrammar` reference-following grammar node and a recursive `Expr` AST, built selectively for the expression fragment. - docs/adr/0026-complex-where-expressions.md — the ADR. - docs/adr/README.md — index entry. - docs/simple-mode-limitations.md — new running list of simple-mode query boundaries vs. advanced SQL, seeded from ADR-0026. - docs/requirements.md — C5a [~] -> [ ] (designed, not yet implemented); new Documentation section with DOC1.
1.5 KiB
1.5 KiB
Simple-mode query limitations
Simple mode's DSL query surface is deliberately a subset of SQL. The DSL is a teaching on-ramp; advanced mode (raw SQL) is the full surface. This document is the running list of what a simple-mode query cannot express that advanced-mode SQL can.
It serves two audiences:
- Students — each entry is the seed of a short explanation of why the boundary exists and what to use instead (often: switch to advanced mode).
- Designers — the consolidated list feeds the future
Q4SQL-subset specification: the inverse view of what the supported subset deliberately leaves out.
The list grows as new simple-mode surface lands; each entry names the ADR that drew the boundary.
WHERE expressions (ADR-0026)
- Comparison operands are a column or a literal, not a
nested expression.
(a > b) = (c > d)— comparing two boolean sub-expressions — cannot be written. Parentheses group boolean sub-expressions, not comparison operands. - A bare column is not a boolean. A predicate always
has an operator: write
Active = true, notActive. - No arithmetic in expressions (
Price * 1.1). - No string concatenation.
- No scalar functions (
upper(Name),length(x), …). - No subqueries, and no
EXISTS.
Query shape (ADR-0026)
- No
ORDER BY.show data … limit <n>orders implicitly by the primary key; explicit ordering is not yet available. - No
LIMIT … OFFSET—limittakes a row count only.