[ES|QL] Multi-column IN subquery (behind snapshot)#155011
[ES|QL] Multi-column IN subquery (behind snapshot)#155011fang-xing-esql wants to merge 1 commit into
Conversation
🔍 Preview links for changed docs⏳ Building and deploying preview... View progress This comment will be updated with preview links when the build is complete. |
ℹ️ Important: Docs version tagging👋 Thanks for updating the docs! Just a friendly reminder that our docs are now cumulative. This means all 9.x versions are documented on the same page and published off of the main branch, instead of creating separate pages for each minor version. We use applies_to tags to mark version-specific features and changes. Expand for a quick overviewWhen to use applies_to tags:✅ At the page level to indicate which products/deployments the content applies to (mandatory) What NOT to do:❌ Don't remove or replace information that applies to an older version 🤔 Need help?
|
Resolves: https://github.com/elastic/esql-planning/issues/1116
Extends
WHERE ... IN (subquery)to support matching against a tuple of columns:The subquery must return exactly as many columns as there are values on the left-hand side, and types must be compatible.
Major Changes
Parsing:
LogicalPlanBuilderproduces aMultiColumnInSubqueryexpression node (parallel to the existing InSubquery for single-column).Resolution.
InSubqueryResolverrewritesMultiColumnInSubqueryinto the same join shapes as single-column:SemiJoin(IN) orAntiJoin(NOT IN)MarkJoinwith a synthetic boolean mark attributeExecution.
AbstractSubqueryJoin.inlineDataMultiColumnhandles the multi-column path once the subquery result is available as a LocalRelation: