Database Query Time Constraint Handling

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Conventional query languages, such as SQL, face challenges in managing query processing times in large databases, leading to unpredictable execution times, which can be mitigated by user-specified constraints but require increased user sophistication and may still result in unknown processing times.

Innovation Solution

The system supports time-constrained queries by accepting a hard time constraint clause in queries, transforming them to ensure completion within the specified time, using timers and limiting row selection or sampling to produce partial or approximate results, thereby controlling query execution and providing confidence intervals for estimates.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Loss of time

If conventional query languages are used without time constraints, then query completeness can be maintained, but query processing time becomes unpredictable and may take inordinate amounts of time

Engineering Contradiction:
Improvequery processing timeVSAvoidquery result completeness
Core Design Contradiction:
Loss of timeVSReliability

Solution Approach 1:

The system performs preliminary analysis of the query execution plan to estimate processing time before actual execution. This allows the system to proactively identify queries that will exceed time constraints and apply transformations in advance, rather than waiting for timeout to occur during execution

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system deliberately returns partial results by applying transformations such as sampling, row limiting, or predicate relaxation when the estimated execution time exceeds the constraint. This accepts incomplete query results as a tradeoff to guarantee execution within the specified time boundary

Inventive Principle:
Principle #16Partial or excessive action

2Loss of time

If users specify query limitations to control processing time, then query execution time can be reduced, but user sophistication is increased and processing time remains unpredictable

Engineering Contradiction:
Improvequery execution timeVSAvoiduser sophistication requirement
Core Design Contradiction:
Loss of timeVSEase of operation

Solution Approach 1:

The system automatically analyzes query execution plans, estimates processing times, and applies appropriate transformations without requiring user intervention. The database management system serves itself by making intelligent decisions about query optimization and transformation based on the specified time constraints

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The system dynamically changes query parameters and execution characteristics based on the time constraint. It transforms the query by adjusting sampling rates, row limits, or predicate conditions to achieve execution within the specified time boundary while maintaining reasonable result quality

Inventive Principle:
Principle #35Parameter changes

3Loss of time

If query transformations are applied to meet time constraints, then query execution time is controlled, but result accuracy and completeness are reduced

Engineering Contradiction:
Improvequery execution timeVSAvoidresult accuracy
Core Design Contradiction:
Loss of timeVSMeasurement precision

Solution Approach 1:

The system dynamically selects and applies different transformation strategies based on the specific query characteristics and time constraint. It adjusts the degree of transformation (e.g., sampling rate, row limit) to achieve the optimal balance between meeting the time constraint and maintaining result accuracy

Inventive Principle:
Principle #15Dynamics

Data Source

PatentUS8015180B2Queries with hard time constraints
Publication Date: 2011.09.06 ORACLE INT CORP
  • US8015180B2 patent drawing
  • US8015180B2 patent drawing
  • US8015180B2 patent drawing

AI summary

Systems, methodologies, media, and other embodiments associated with supporting queries with hard time constraints are described. One exemplary system embodiment includes logic for accepting a query having a hard time constraint. The example system may also include logic for selectively rewriting the query having the hard time constraint into a query having a row limitation or a sample percentage limitation. In one example, the row limitation or sample percentage limitation are computed by repetitively comparing an estimated query execution time to the hard time constraint. The example system may also include logic for establishing a timer(s) associated with the rewritten query.