Spatial Statistics Collection via Grid-Based MBR Subdivision
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
The challenge lies in collecting statistics for spatial data types in commercial database systems, as existing methods like the histogram model are not applicable to multi-dimensional spatial data, making it difficult for optimizers to predict row counts for spatial queries and join operations.
Innovation Solution
A method is introduced to collect statistics on spatial data by designating processing nodes to form Minimum Bounding Rectangle (MBR) Trees, merging these into a system-wide MBR, subdividing it into cells, and creating a Spatial Statistical Context Block (SSCB) that is broadcast for population, allowing for the estimation of row counts for spatial queries.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Adaptability or versatility
If the histogram model is used for statistical collection, then scalar data statistics can be effectively tracked, but spatial multi-dimensional data statistics cannot be collected
Solution Approach 1:
The spatial data space is segmented into a grid structure with multiple cells. Each cell can independently store statistical information, allowing the system to handle complex multi-dimensional spatial data by breaking it down into manageable discrete units that can be processed and stored efficiently
Solution Approach 2:
The patent transforms spatial multi-dimensional data into a multi-dimensional grid structure where statistical information is organized along multiple axes. This dimensional transformation allows spatial relationships to be captured and queried effectively, converting continuous spatial data into a discrete multi-dimensional array format
2Adaptability or versatility
If spatial data types are introduced to support spatial operations, then spatial query capabilities are enhanced, but statistical collection mechanisms become inadequate
Solution Approach 1:
The grid-based statistical structure serves multiple functions: it stores spatial data distribution information, supports various spatial operations (intersection, containment, distance calculations), and provides optimization hints for query execution. This universal structure replaces multiple specialized mechanisms with a single multi-functional system
Solution Approach 2:
The patent introduces an intermediary statistical collection mechanism that bridges spatial data storage and query optimization. This intermediary layer processes spatial data through grid cells and generates statistical information that mediates between raw spatial data and optimizer decisions, simplifying the overall system architecture
3Device complexity
If no spatial statistics are collected, then the existing statistical framework remains simple, but the optimizer cannot predict row counts for spatial queries
Solution Approach 1:
The system performs preliminary statistical analysis by pre-computing and storing spatial statistics in grid cells before queries are executed. This preliminary action populates the grid structure with frequency and distribution information that the optimizer can immediately use for accurate row count predictions without performing complex calculations at query time
Data Source
AI summary
Techniques for collecting statistics of column data or R-Tree indexes are provided. A distributed database system includes a plurality of processing nodes controlling portions of spatial data. The nodes are instructed to create minimum bounding rectangles (MBR's) for their spatial data or R-Trees. The individual MBR's are merged and reformatted into a grid of equally sized cells. Each processing node is provided a copy of the grid to update based on statistics of each processing node's spatial data for a target table. The updated grids are then merged into a single grid and used by an optimizer to evaluate queries before the queries are executed.


