Skip to content

opt: support lookup anti/semi join#38625

Merged
craig[bot] merged 1 commit intocockroachdb:masterfrom
RaduBerinde:lookup-semi-join
Jul 8, 2019
Merged

opt: support lookup anti/semi join#38625
craig[bot] merged 1 commit intocockroachdb:masterfrom
RaduBerinde:lookup-semi-join

Conversation

@RaduBerinde
Copy link
Copy Markdown
Member

Enable support for lookup anti/semi joins. Some adjustments were
needed in the distsql physical planner and the library, but nothing in
the optimizer itself.

Verified that the TPCH query that changed is faster (~0.9s vs ~1.3s on
single node SF1).

Release note: None

@RaduBerinde RaduBerinde requested review from a team, andy-kimball and justinj July 2, 2019 20:23
@RaduBerinde RaduBerinde requested a review from a team as a code owner July 2, 2019 20:23
@RaduBerinde RaduBerinde requested review from a team July 2, 2019 20:23
@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

Copy link
Copy Markdown
Contributor

@justinj justinj left a comment

Choose a reason for hiding this comment

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

the 1-line change (+ tests) in the opt codebase lgtm :) should we consider tagging in someone from exec? I think @jordanlewis shepherded the original PR for this

Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @andy-kimball and @justinj)

@RaduBerinde RaduBerinde requested a review from jordanlewis July 3, 2019 10:55
Copy link
Copy Markdown
Member

@jordanlewis jordanlewis left a comment

Choose a reason for hiding this comment

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

:lgtm: very cool!

Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @andy-kimball, @jordanlewis, and @RaduBerinde)


pkg/sql/distsqlpb/processors_sql.proto, line 181 at r1 (raw file):

  // If populated (lookup join), the `joinReader` will perform a lookup join
  // and the "internal columns" will be the concatenation of the input stream
  // columns followed by the table columns (except for semi/anti join).

nit: might as well spell it out here. (except for semi/anti join, which don't output any table columns).

Enable support for lookup anti/semi joins. Some adjustments were
needed in the distsql physical planner and the library, but nothing in
the optimizer itself.

Verified that the TPCH query that changed is faster (~0.9s vs ~1.3s on
single node SF1).

Release note: None
Copy link
Copy Markdown
Member Author

@RaduBerinde RaduBerinde 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+

Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (and 1 stale) (waiting on @andy-kimball)

craig bot pushed a commit that referenced this pull request Jul 8, 2019
38625: opt: support lookup anti/semi join r=RaduBerinde a=RaduBerinde

Enable support for lookup anti/semi joins. Some adjustments were
needed in the distsql physical planner and the library, but nothing in
the optimizer itself.

Verified that the TPCH query that changed is faster (~0.9s vs ~1.3s on
single node SF1).

Release note: None

Co-authored-by: Radu Berinde <radu@cockroachlabs.com>
@craig
Copy link
Copy Markdown
Contributor

craig bot commented Jul 8, 2019

Build succeeded

@craig craig bot merged commit 9e9555b into cockroachdb:master Jul 8, 2019
@RaduBerinde RaduBerinde deleted the lookup-semi-join branch July 8, 2019 20:01
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.

4 participants