Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Performance improvements for singleton sibling lists
Previously all sibling lists would result in the generation of an SQL UNION ALL for each of the siblings to avoid the generation of a potentially large cross. However this union adds cost and complexity to the resulting SQL query and is unnecessary where we can detect that all but one of the siblings has length at most 1. This PR detects that condition by looking for Limit(1, ...) and Unique nodes in the query and avoids the UNION in that case.
- Loading branch information