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

cherrypick-1.1: sqlbase: fix encoding of index value when using unspecified columns #20074

Merged
merged 1 commit into from
Nov 15, 2017

Conversation

vivekmenezes
Copy link
Contributor

prior to this fix we would treat an unspecified column as a NULL value
when encoding a column for an index key, but not when encoding it in the
index as the value part of the key:value index pair.

For the storing case, we would pick up the first specified value
for the unspecified value and encode it in the index creating a
completely broken index!

For the composite encoding case it would crash. See #20000

fixes #20000

prior to this fix we would treat an unspecified column as a NULL value
when encoding a column for an index key, but not when encoding it in the
index as the value part of the key:value index pair.

For the storing case, we would pick up the first specified value
for the unspecified value and encode it in the index creating a
completely broken index!

For the composite encoding case it would crash. See cockroachdb#20000

fixes cockroachdb#20000
@vivekmenezes vivekmenezes requested review from knz and a team November 15, 2017 17:38
@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Contributor

@lgo lgo left a comment

Choose a reason for hiding this comment

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

LGTM

@vivekmenezes vivekmenezes merged commit 50c5792 into cockroachdb:release-1.1 Nov 15, 2017
@vivekmenezes vivekmenezes deleted the vivek/20001 branch November 15, 2017 20:58
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.

3 participants