Repository navigation
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Contributor
Author
|
The VS Code Extension Smoke (windows-latest) failure is a download abort while fetching the VS Code 1.123.2 archive (251 MB, three retries, "Error: aborted") - the same smoke subset passes on macos-latest, and the change does not touch the extension. Everything else is green. |
niukanen1
force-pushed
the
fix/limit-all-bound-1926
branch
from
October 24, 2026 10:53
a380beb to
9af9d88
Compare
Contributor
Author
|
Rebased onto the current main (1d5f63b) to clear the conflict: kept the LIMIT ALL tests next to the CTE tests that landed in the meantime and merged both grammar keys into the golden line |
This branch has not been deployed
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.
Description
PostgreSQL documents
LIMIT { count | ALL }, but the shared query limiter only recognized a numericLIMIT nfor this dialect, soSELECT * FROM t LIMIT ALLwas read as unbounded and rewritten toLIMIT ALL LIMIT 500- two LIMIT clauses, which PostgreSQL rejects (#1926). The word is now declared on the Postgres grammar'snonNumericRowBounds, the same route Snowflake'sNULLtook (SF-021): the statement's own unlimited bound is detected, nothing is appended, andforceLimitreplaces it.ALLis accepted for the LIMIT count only - the FETCH spelling has no ALL arm in PostgreSQL's grammar - so aFETCH FIRST ALL ROWS ONLYis still the engine's own refusal, just without a second bound appended to it. Spark's documented behavior (it refusesLIMIT ALLitself) is unchanged.Fixes #1926
Verification
bun tests/run-tests.ts tests/unit/db/query-limiter.test.ts- new describe with the case variants (ALL/all/All), a trailing comment, a CTE,forceLimit, literal/comment false positives, and eight other dialects readingLIMIT ALLexactly as before; all 307 passbun tests/run-tests.ts tests/unit/db/sql-grammar/golden.test.ts- golden snapshot regenerated for the one grammar fieldbun tests/run-tests.ts tests/integration/db/postgres-provider.test.ts-prepareQuery()keepsLIMIT ALLuntouched; all pass