Query Pipeline Early Filtering for Top-K Join Pruning

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing database query plans are inefficient when a top K sort operation is performed subsequent to a join operation, as they waste processing cycles by processing elements that are not needed to fulfill the command due to the system's inability to know whether further rows have a join partner without further knowledge.

Innovation Solution

Implementing an early filter with intra-pipeline predicate back-propagation, where a dynamic variable is introduced to push a specialized filter down below the join operation, allowing for efficient pruning of elements before they are processed by the join operation.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If a top K sort operation is performed subsequent to a join operation in existing database query plans, then the query can be executed, but processing cycles are wasted by processing elements that are not needed to fulfill the command

Engineering Contradiction:
Improvequery execution efficiencyVSAvoidprocessing cycles
Core Design Contradiction:
ProductivityVSLoss of energy

Solution Approach 1:

The patent applies preliminary action by pushing a specialized filter down below the join operation to prune elements before they are processed by the join. This early filtering action occurs in advance of the join operation, preventing unnecessary elements from entering the processing pipeline and thus eliminating wasted processing cycles while maintaining correct query execution.

Inventive Principle:
Principle #10Preliminary action

2Productivity

If elements are filtered early in the pipeline, then processing efficiency is improved, but the system must introduce additional filter mechanisms below the join operation

Engineering Contradiction:
Improveprocessing efficiencyVSAvoidquery plan structure
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent introduces an intermediary specialized filter mechanism that acts as a mediator between the join operation and the data flow. This filter serves as an intermediate component that enables early pruning of unnecessary elements without fundamentally altering the core join operation, thus improving processing efficiency while adding controlled complexity through a targeted intermediate component.

Inventive Principle:
Principle #24Intermediary (Mediator)

3Reliability

If the system processes all elements through the join operation, then completeness is maintained, but unnecessary elements consume processing resources

Engineering Contradiction:
Improvequery result completenessVSAvoidprocessing resource utilization
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent applies local quality by implementing a specialized filter with specific pruning criteria tailored to the top K sort operation's needs. This localized filtering approach applies quality control selectively at the appropriate position in the query plan, ensuring that only relevant elements proceed through the join operation while maintaining the completeness of necessary results and eliminating redundant processing.

Inventive Principle:
Principle #3Local quality

Data Source

PatentUS20260037512A1Adaptive early filtering with intra-pipeline predicate back-propagation
Publication Date: 2026.02.05 SAP SE
  • US20260037512A1 patent drawing
  • US20260037512A1 patent drawing
  • US20260037512A1 patent drawing

AI summary

In an example embodiment, an early filter is applied with a query plan using intra-pipeline predicate back-propagation. Specifically, the query plan may be thought of as a pipeline of operations. A runtime variable var may be introduced, and a specialized filter using var may be pushed down below the join operation. Var is a dynamic variable that is updated to track a value from the sort or similar operation (such as max (heap), reflecting the maximum value of a max-heap used by the sort or similar operation). The runtime variable gets initialized once the heap reaches a minimum number of elements (such as K in the case of a top K sort). Thus, before the heap reaches that minimum number of elements, the filter does not apply. Once the heap does reach that minimum number of elements, the filter does apply and acts to filter elements. Since the filter has been pushed down below the join operation, this saves processing cycles.