Hierarchical Database Index Estimating Data Cardinality
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current database management systems face inaccuracies in estimating data returned by a predicate due to unrepresentative samples, stale statistics, and limited precision of histograms, leading to inefficient query optimization.
Innovation Solution
The system utilizes a hierarchical database index with balanced nodes to estimate data, allowing for precise calculations based on child nodes or content, eliminating the need for representative sampling and enhancing precision by using equal area histograms.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Use of energy by moving object
If sampling or histogram approach is used to estimate data, then resource consumption is reduced, but estimation accuracy deteriorates
Solution Approach 1:
The patent uses index structures (B-trees, B+ trees) as copies or representations of the actual data distribution. Instead of sampling the real data, the system creates histogram estimates from index structures that mirror the data organization, providing accurate estimates without consuming resources to access the actual data.
Solution Approach 2:
The patent introduces index structures as an intermediary between the query optimizer and the actual data. These indexes serve as mediators that provide estimation information without requiring direct access to or sampling of the underlying data, thus maintaining accuracy while reducing resource consumption.
2Speed
If histograms are used to represent data distribution, then processing speed is improved, but precision deteriorates due to limited precision and unrepresentative samples
Solution Approach 1:
The patent pre-computes and maintains histogram statistics in the index structures during data insertion and update operations. This preliminary action ensures that when queries need estimation, the histograms are already prepared and available, providing both speed and accuracy without requiring complex real-time computations.
Solution Approach 2:
The patent creates accurate copies of data distribution characteristics through index structures that are built to reflect the actual data organization. These index-based histograms serve as precise copies that maintain the statistical properties of the underlying data while enabling fast processing.
3Measurement precision
If index structures are used to estimate data, then estimation accuracy is improved, but device complexity increases
Solution Approach 1:
The patent makes the index structures serve multiple functions: they provide both the actual data access paths for queries and simultaneously serve as the basis for cardinality estimation. This multi-functionality eliminates the need for separate estimation mechanisms, reducing overall system complexity while maintaining high accuracy.
Solution Approach 2:
The patent merges the estimation function with the existing index structures. Instead of maintaining separate histograms or sampling mechanisms, the system combines estimation capabilities directly into the index, allowing the same data structure to serve both access and estimation purposes.
Data Source
AI summary
Disclosed herein are a system, non transitory computer-readable medium, and method for estimating database performance. A request for an estimate of data is read. The estimate is calculated based at least partially on a node located in a data structure.


