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

Query: Validate SelectExpression for outer referencing when lifting Apply into Join #17112

Closed
smitpatel opened this issue Aug 12, 2019 · 0 comments · Fixed by #17182
Closed
Assignees
Labels
closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. type-bug
Milestone

Comments

@smitpatel
Copy link
Contributor

CROSS APPLY can be converted to INNER JOIN
OUTER APPLY can be converted to LEFT JOIN.
But only if the inner SelectExpression does not contain reference to outer.

@ajcvickers ajcvickers added this to the 3.0.0 milestone Aug 14, 2019
smitpatel added a commit that referenced this issue Aug 15, 2019
smitpatel added a commit that referenced this issue Aug 15, 2019
smitpatel added a commit that referenced this issue Aug 15, 2019
@smitpatel smitpatel added the closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. label Aug 15, 2019
smitpatel added a commit that referenced this issue Aug 15, 2019
- Validate inner select expression after extracting join predicate that it does not contain reference to outer.
- Also apply same logic for generating collections in projection.
- Identify DefaultIfEmpty in collectionSelector of SelectMany accurately.

This fix up a lot of N+1 evaluation queries.

Resolves #17112
Resolves #16311
smitpatel added a commit that referenced this issue Aug 15, 2019
- Validate inner select expression after extracting join predicate that it does not contain reference to outer.
- Also apply same logic for generating collections in projection.
- Identify DefaultIfEmpty in collectionSelector of SelectMany accurately.

This fix up a lot of N+1 evaluation queries.

Resolves #17112
Resolves #16311
smitpatel added a commit that referenced this issue Aug 15, 2019
- Validate inner select expression after extracting join predicate that it does not contain reference to outer.
- Also apply same logic for generating collections in projection.
- Identify DefaultIfEmpty in collectionSelector of SelectMany accurately.

This fix up a lot of N+1 evaluation queries.

Resolves #17112
Resolves #16311
@ajcvickers ajcvickers modified the milestones: 3.0.0, 3.0.0-preview9 Aug 21, 2019
@ajcvickers ajcvickers modified the milestones: 3.0.0-preview9, 3.0.0 Nov 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. type-bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants