Query runtime for multi-layer composition of queries
US12332894B2 · kind B2 · utility
Assignee
Inventor
Key dates
| Filing date | Sep 7, 2023 |
| Grant date | Jun 17, 2025 |
| Priority date | — |
| Expiry date | Sep 7, 2043 |
Classification
- Technology area (CPC G)Physics
- CPC primaryG06F16/24539
- WIPO fieldComputer technology
- WIPO sectorElectrical engineering
Abstract
The present disclosure describes a system and method for optimizing SQL queries, specifically addressing challenges in handling and optimization of nested Common Table Expressions (CTEs). The system comprises a SQL optimization engine configured to receive SQL scripts from a SQL editor application and output optimized SQL to a query engine for execution on a database. The optimization engine utilizes three primary stages: a CTE normalization stage, a materialization stage, and a caching stage. The CTE normalization stage unnests nested CTEs into single-level CTEs. The materialization stage implements a materialized Create Table As Select (CTAS) strategy for materializing the base query. The caching stage enables reusability of the materialized base query across multiple queries, increasing efficiency and performance. This system provides technical solutions to enhance the capabilities of SQL engines that lack native support for nested CTEs, offering improved query performance and management of large datasets.
Source: USPTO / EPO open patent data. Objective bibliographic and citation counts.