[fix](sql-functions) provide setup data for window-function examples querying an undefined table#3874
Merged
morningman merged 1 commit intoJun 3, 2026
Conversation
…querying an undefined table
The LAG, LEAD, NTILE, RANK and ROW_NUMBER pages each show a `SELECT ... FROM <table>`
example with an expected result, but never define the table on the page, so the
examples cannot be run or reproduced ("table does not exist").
Add the missing CREATE TABLE + INSERT for each table (`stock_ticker` for LAG/LEAD,
`student_scores`, `employees`, `int_t`), carried in a standard HTML comment
(`<!-- setup-sql ... -->`) before the example. As an HTML comment it does not change
the rendered page, and no documented expected output is modified.
Table contents were reverse-derived from the output already printed on each page and
verified end-to-end on the matching release clusters: version-4.x on 4.1.1, version-3.x
on 3.1.4, version-2.1 on 2.1.11, and dev/current on a master build. On every tree the
examples failed with "table does not exist" before and now resolve and match the
documented output.
Pages updated in EN + ZH across dev/current, version-4.x, version-3.x and version-2.1.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
The
LAG,LEAD,NTILE,RANKandROW_NUMBERwindow-function pages each show aSELECT ... FROM <table>example with an expected result, but never define the table on the page. As written these examples cannot be run or reproduced — a reader who copies them getsTable [...] does not exist.This PR adds the missing
CREATE TABLE+INSERTfor each table, carried in a standard HTML comment (<!-- setup-sql ... -->) just before the example. Because it is an HTML comment, the rendered page is unchanged and no documented expected output is modified — it only records the data the examples already assume, making each example self-contained and reproducible.Table contents were reverse-derived from the output already printed on each page and verified end-to-end on the matching release cluster for every doc tree.
Pages and tables
LAG/LEADstock_tickerNTILEstudent_scoresRANKemployeesROW_NUMBERint_tEach page is updated in EN + ZH across the dev/
current,version-4.x,version-3.xandversion-2.1doc trees (40 files). Verification clusters: 4.1.1 (4.x), 3.1.4 (3.x), 2.1.11 (2.1), master build (dev). On every tree the affected examples failed with "table does not exist" before this change and pass (output matches the doc) after it. Noja-sourcechanges.🤖 Generated with Claude Code