Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

opt/exec: add passthrough cols to DELETE USING result cols in explain #105932

Merged
merged 1 commit into from
Jul 5, 2023

Conversation

michae2
Copy link
Collaborator

@michae2 michae2 commented Jun 30, 2023

Now that we support DELETE USING, delete nodes can have passthrough columns. Add these to the result columns used by EXPLAIN (TYPES).

Fixes: #105803

Release note (sql change): Fix an internal error when using EXPLAIN (TYPES) on a DELETE FROM ... USING ... RETURNING statement.

@michae2 michae2 requested a review from a team as a code owner June 30, 2023 20:20
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@michae2 michae2 added the backport-23.1.x Flags PRs that need to be backported to 23.1 label Jun 30, 2023
Copy link
Member

@yuzefovich yuzefovich left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 2 of 2 files at r1, all commit messages.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @DrewKimball and @michae2)


-- commits line 9 at r1:
nit: s/sql change/bug fix/. Also perhaps mention that the bug was introduced in 23.1.0.

Copy link
Collaborator

@DrewKimball DrewKimball left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 2 of 2 files at r1, all commit messages.
Reviewable status: :shipit: complete! 2 of 0 LGTMs obtained (waiting on @michae2)

Now that we support `DELETE USING`, delete nodes can have passthrough
columns. Add these to the result columns used by `EXPLAIN (TYPES)`.

Fixes: cockroachdb#105803

Release note (bug fix): Fix an internal error when using
`EXPLAIN (TYPES)` on a `DELETE FROM ... USING ... RETURNING` statement
which was introduced in v23.1.0.
@michae2 michae2 force-pushed the deleteUsingExplain branch from df83ab2 to 5960881 Compare July 5, 2023 17:06
Copy link
Collaborator Author

@michae2 michae2 left a comment

Choose a reason for hiding this comment

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

TFTRs!

bors r=yuzefovich,DrewKimball

Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (and 2 stale) (waiting on @yuzefovich)


-- commits line 9 at r1:

Previously, yuzefovich (Yahor Yuzefovich) wrote…

nit: s/sql change/bug fix/. Also perhaps mention that the bug was introduced in 23.1.0.

Good point! Done.

@craig
Copy link
Contributor

craig bot commented Jul 5, 2023

Build succeeded:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-23.1.x Flags PRs that need to be backported to 23.1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

sql: index out of range during EXPLAIN (TYPES) of DELETE FROM USING
4 participants