Skip to content

Conversation

mhamza15
Copy link

@mhamza15 mhamza15 commented Sep 3, 2025

Description

This is a backport of vitessio#18369

Related Issue(s)

Checklist

  • "Backport to:" labels have been added if this change should be back-ported
  • Tests were added or are not required
  • Documentation was added or is not required

Deployment Notes

@Copilot Copilot AI review requested due to automatic review settings September 3, 2025 13:32
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This pull request ensures that parsed comments are properly preserved when merging subqueries with outer queries in the Vitess query planner. The change specifically sets the comments from the outer Route operator to the merged operator when subqueries are merged.

  • Preserves SQL comments during subquery merging operations
  • Adds test coverage for comment handling in various subquery scenarios

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
go/vt/vtgate/planbuilder/operators/subquery_planning.go Adds logic to preserve comments from outer Route when merging subqueries
go/vt/vtgate/planbuilder/testdata/select_cases.json Adds test cases to verify comment preservation in subquery scenarios

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

* fix actions

Signed-off-by: Mohamed Hamza <[email protected]>

* fix actions

---------

Signed-off-by: Mohamed Hamza <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants