-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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: generate spans for IN filters #26708
Conversation
@RaduBerinde I can rework this if you'd prefer we did non-tight single-col spans, I had the impression from the conversation that we settled on this approach but if you think single-cols would work better then I'm happy to change it. |
The single composite span is ok for now. We can always go back and add single-col spans if we need that. Review status: complete! 0 of 0 LGTMs obtained pkg/sql/opt/memo/constraint_builder.go, line 212 at r1 (raw file):
We may still be able to generate a constraint on other columns (e.g. pkg/sql/opt/memo/constraint_builder.go, line 225 at r1 (raw file):
I think it's no longer tight in this case. At least not the way we define Comments from Reviewable |
Review status: complete! 0 of 0 LGTMs obtained pkg/sql/opt/memo/constraint_builder.go, line 212 at r1 (raw file): Previously, RaduBerinde wrote…
Done. pkg/sql/opt/memo/constraint_builder.go, line 225 at r1 (raw file): Previously, RaduBerinde wrote…
Ah, good call, I hadn't considered that distinction. Done. Comments from Reviewable |
Review status: complete! 0 of 0 LGTMs obtained (and 1 stale) pkg/sql/opt/memo/constraint_builder.go, line 217 at r2 (raw file):
[nit] it's annoying to have to set this in two places, maybe just do pkg/sql/opt/memo/constraint_builder.go, line 247 at r2 (raw file):
[nit] pkg/sql/opt/memo/constraint_builder.go, line 255 at r2 (raw file):
You could use Comments from Reviewable |
Review status: complete! 0 of 0 LGTMs obtained (and 1 stale) pkg/sql/opt/memo/constraint_builder.go, line 217 at r2 (raw file): Previously, RaduBerinde wrote…
Done. pkg/sql/opt/memo/constraint_builder.go, line 247 at r2 (raw file): Previously, RaduBerinde wrote…
Done. pkg/sql/opt/memo/constraint_builder.go, line 255 at r2 (raw file): Previously, RaduBerinde wrote…
Pretty straightforward change! Done. Comments from Reviewable |
Reviewed 3 of 5 files at r1, 1 of 2 files at r2, 1 of 1 files at r3. Comments from Reviewable |
TFTR! bors r+ |
Build failed |
Review status: complete! 1 of 0 LGTMs obtained (and 1 stale) pkg/sql/opt/exec/execbuilder/testdata/select_index, line 470 at r3 (raw file):
NIT: Remove comment now that this is fixed. pkg/sql/opt/memo/constraint_builder.go, line 193 at r3 (raw file):
What's the purpose of setting pkg/sql/opt/memo/testdata/logprops/constraints, line 760 at r3 (raw file):
What about test where RHS contains something that's not a Tuple? Also, to make sure testing is complete, one thing I often do is deliberately introduce subtle bugs into different parts of the code I'm testing, and make sure that one of my tests fails. pkg/sql/opt/xform/testdata/external/tpcc, line 604 at r3 (raw file):
Nice. Comments from Reviewable |
This code is largely based off of makeSpansForTupleIn, though I wasn't able to reuse much of it since the context is slightly different. Also fix up a CREATE STATISTICS statement and modify a TPCC query. Release note: None
Review status: complete! 0 of 0 LGTMs obtained (and 2 stale) pkg/sql/opt/memo/constraint_builder.go, line 193 at r3 (raw file): Previously, andy-kimball (Andy Kimball) wrote…
We talked on slack - looking at the assembly it does look like it will re-evaluate pkg/sql/opt/memo/testdata/logprops/constraints, line 760 at r3 (raw file):
so I'll add a check for safety just in case this changes. Comments from Reviewable |
bors r+ |
26708: opt: generate spans for IN filters r=justinj a=justinj This code is largely based off of makeSpansForTupleIn, though I wasn't able to reuse much of it since the context is slightly different. Also fix up a CREATE STATISTICS statement and modify a TPCC query. Release note: None Co-authored-by: Justin Jaffray <[email protected]>
Build succeeded |
This code is largely based off of makeSpansForTupleIn, though I wasn't
able to reuse much of it since the context is slightly different.
Also fix up a CREATE STATISTICS statement and modify a TPCC query.
Release note: None