Repository navigation
docs: materialized view column types and limitations (engine 0.25.0) - #464
Merged
Merged
Conversation
A view now declares its columns with the types a query of its definition reports (KEYWORD/TEXT and computed columns keep theirs), and reads its WHERE, HAVING and calculations with the source types. Document that, the real DESCRIBE MATERIALIZED VIEW output, the SUM column type the web page already carried, and three limitations measured on Elasticsearch 8.x; point the boolean rows of operators.md at the view exception. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
fupelaqu
marked this pull request as ready for review
November 15, 2026 08:00
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The materialized-view engine now builds on engine 0.25.0. This PR documents what changes for a view, and the limitations measured while verifying it, on
documentation/sql/materialized_views.md, with one pointer onoperators.md. The web twin goes into the open web documentation PR for 0.25.0.What changes
SELECTlist with the type a query of its definition reports, table by table over a JOIN.KEYWORDorTEXTsource column keeps its mapping type, and a computed column keeps the type its script writes.DATEDIFFper-group calculation is nowBIGINT.DESCRIBE MATERIALIZED VIEWreports the declared types, while a query over the view reports a query's types.WHERE,HAVINGand per-group calculations are typed as in a query, sob = nandb <> n(aBOOLEANcolumn against a number column) are now answered.DROP+CREATE.DESCRIBE MATERIALIZED VIEWexample replaced with the real output for the page's example view. The previous example was already wrong:customer_zipisKEYWORD,customer_name_upperisVARCHAR,effective_dateisDATE. The real output has 13 rows, including thekeywordsub-fields, the columns the view's stages read, and_last_updated.SUMcolumn type (BIGINTover integers,DOUBLEoverREAL/DOUBLE): the web page already said this, and the core page did not.GROUP BYkey,WHERE k = n) is still refused at creation with HTTP 400, although a query answers it since 0.25.0;WHERE YEAR(created_at) = 2024creates the view, but it stores no rows;COALESCEover aDATEcompared with a string, andWHERE b > 0over aBOOLEAN, fail at creation with HTTP 500.operators.md: "the boolean rows apply everywhere" now names theb > 0exception in a view'sWHERE.Evidence
Every statement comes from runs on Elasticsearch 8.x of the materialized-view integration suites and of probes run on both engine versions, with DuckDB as a third reference. The
DESCRIBEtable is copied from a real run. The ES-dependent limitation rows say "measured on Elasticsearch 8.x", because no other major was measured. An independent review checked every statement against those runs, and its findings are applied.Recorded, not fixed
SUMorAVGis refused, while one grouped by an expression is created, and so are single-table computed columns. The rule has not been characterized, so the page does not describe it yet. Some single-tableHAVINGexamples on this page have the shape of a refused body.🤖 Generated with Claude Code