Dynamic Operator Pruning from Intermediate Query Results

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing database query optimization techniques fail to efficiently prune query plans based on dynamic and intermediate results, leading to unnecessary resource utilization and inefficiencies in processing large datasets.

Innovation Solution

Implement dynamic pruning of query plans by detecting shared empty state objects between join operators and applying pruning conditions, utilizing direct, forward, and backward pruning rules to mark and propagate pruned operators, thereby optimizing resource usage.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If dynamic pruning based on intermediate results is implemented, then query execution efficiency is improved, but system complexity increases

Engineering Contradiction:
Improvequery execution efficiencyVSAvoidsystem complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The system performs preliminary actions by pre-defining operator pruning conditions and state object dependencies before query execution. The query plan is generated with embedded pruning rules that automatically trigger based on intermediate results, eliminating the need for complex runtime analysis and reducing overall system complexity while maintaining high efficiency

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system implements feedback mechanisms by monitoring intermediate query results and using them to dynamically adjust the query plan execution. When intermediate results indicate that certain operators will not contribute to the final outcome, the system feeds this information back to prune those operators, improving efficiency without requiring complex external control systems

Inventive Principle:
Principle #23Feedback

2Loss of energy

If comprehensive operator pruning conditions are defined, then resource utilization is optimized, but query plan complexity increases

Engineering Contradiction:
Improveresource utilizationVSAvoidquery plan complexity
Core Design Contradiction:
Loss of energyVSDevice complexity

Solution Approach 1:

The system segments the query plan into distinct operators with defined input-output relationships and state object dependencies. Each operator is analyzed independently for pruning conditions based on its specific role in the query pipeline, allowing for targeted optimization without requiring complex analysis of the entire query plan as a monolithic structure

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The system changes parameters by defining specific pruning conditions based on intermediate result states (e.g., empty results, null values, cardinality thresholds). These parameter-based conditions allow the system to optimize resource utilization dynamically without hardcoding complex decision logic, maintaining query plan simplicity while achieving efficient resource usage

Inventive Principle:
Principle #35Parameter changes

Data Source

PatentUS12436951B2Dynamic operator pruning based on state dependencies and intermediate results
Publication Date: 2025.10.07 SAP SE
  • US12436951B2 patent drawing
  • US12436951B2 patent drawing
  • US12436951B2 patent drawing

AI summary

In some implementations, there is provided a method including generating a query plan including in a first pipeline a first join operator and in a second pipeline a second join operator; executing at least a portion of the query plan including the first pipeline and the first join operator; detecting, based on the at least one operator usage state and the at least one operator pruning condition, an empty state object shared between the first join operator and the second join operator in the second pipeline; and processing, by the at least one operator pruning condition, an indication of the empty state object, wherein the least one operator pruning condition is associated with the second join operator and includes at least a first rule to mark the second join operator for pruning.