Repository navigation
Add regression test for INSERT into table referenced by materialized view via renaming subquery JOIN - #108079
Merged
Conversation
…view via renaming subquery JOIN Inserting into a table that a materialized view references inside a column-renaming subquery on one side of a JOIN used to fail with a confusing `Not found column low_un in block` error. The scenario now works correctly on master (the insert succeeds and the view receives the correctly joined rows), so add a stateless regression test. Closes: #836 Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Contributor
|
Workflow [PR], commit [94dd389] Summary: ✅ AI ReviewSummaryThis PR adds a stateless regression shell test for inserting into a table referenced by a materialized view whose query joins a column-renaming subquery with Final VerdictStatus: ✅ Approve |
…n test The new test `04403_mv_insert_renaming_subquery_join` used `lowerUTF8`, which requires ICU and is therefore unavailable in the Fast test build (`lowerUTF8.cpp` is guarded by `#if USE_ICU`), so the test failed with `Function with name lowerUTF8 does not exist`. The function was only used for case-insensitive matching of ASCII data, so replace it with `lower`, which yields identical results on this data and is always available. Also convert the test from `.sql` to `.sh` and run the scenario under both `enable_analyzer = 0` and `enable_analyzer = 1`, as suggested by the reviewer. The analyzer setting is not randomized by the stateless test harness, so the old-analyzer path (which the issue closure also claims to be fixed) was not actually exercised by the single-run `.sql` test. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Felixoid
approved these changes
Jun 23, 2026
Contributor
LLVM Coverage Report
Changed lines: No C/C++ source files changed — skipping uncovered code analysis. Newly covered by added/modified tests: 378 line(s), 16 function(s) across 125 file(s) · Details Top files
|
zeekay
pushed a commit
to hanzoai/datastore
that referenced
this pull request
Sep 11, 2026
…ng-subquery-join Add regression test for INSERT into table referenced by materialized view via renaming subquery JOIN
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.
Closes: #836
Issue #836 reported that inserting into a table referenced by a materialized view failed with a confusing
Not found column low_un in block. There are only columns: ...error, when the view'sSELECTreferenced the source table inside a column-renaming subquery on one side of aJOIN.This no longer reproduces on current master: the
INSERTsucceeds and the materialized view receives the correctly joined rows. Verified with the exact structure from the report (a renaming subquery on the left of anALL INNER JOIN, with aUNION ALLon the right, joinedUSING low_un), under both the new analyzer (default) and the old analyzer (enable_analyzer=0), with identical output.This pull request adds a stateless regression test so the scenario stays fixed. The analyzer is not randomized by the test harness, so the test is a shell script that runs the scenario explicitly under both
enable_analyzer = 0andenable_analyzer = 1.Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Added a regression test for inserting into a table referenced by a materialized view whose query joins a column-renaming subquery using
USING, under both analyzers.Version info
26.7.1.220(included in26.7and later)