Query optimization
First Claim
Patent Images
1. A method, comprising:
- generating an On-Line Analytical Processing (OLAP) query having a first expression for retrieving report data and other report data from an OLAP cache and a second expression for retrieving additional report data from the OLAP cache;
executing the first expression to retrieve the report data that is stored in the OLAP cache to respond to the first expression;
for the other report data that is not stored in the OLAP cache to respond to the first expression,identifying the other report data to be retrieved for the first expression and the additional report data to be retrieved for the second expression that is not stored in the OLAP cache by;
identifying OLAP objects referenced in the first expression and the second expression;
mapping the OLAP objects to relational database tables in a relational database using a mapping stored in an OLAP database; and
grouping OLAP objects from the first expression and the second expression that are mapped to a same relational database table from the relational database tables;
generating a relational query to retrieve the other report data to be used to respond to the first expression and the additional report data to be used to respond to the second expression from the relational database;
executing the relational query to retrieve the other report data and the additional report data from the relational database;
storing the other report data in the OLAP cache;
using the other report data stored in the OLAP cache to respond to the first expression; and
pre-loading the additional report data in the OLAP cache in anticipation of execution of the second expression; and
subsequently executing the second expression by retrieving the additional report data to be used to respond to the second expression from the OLAP cache instead of from the relational database.
1 Assignment
0 Petitions
Accused Products
Abstract
Provided are techniques for generating a relational query. Information is collected from a query specification and a model for an On-Line Analytical Processing (OLAP) query having at least a first expression and a second expression. The collected information is used to generate a relational query to retrieve report data to be used to satisfy the first expression and the second expression.
-
Citations
18 Claims
-
1. A method, comprising:
-
generating an On-Line Analytical Processing (OLAP) query having a first expression for retrieving report data and other report data from an OLAP cache and a second expression for retrieving additional report data from the OLAP cache; executing the first expression to retrieve the report data that is stored in the OLAP cache to respond to the first expression; for the other report data that is not stored in the OLAP cache to respond to the first expression, identifying the other report data to be retrieved for the first expression and the additional report data to be retrieved for the second expression that is not stored in the OLAP cache by; identifying OLAP objects referenced in the first expression and the second expression; mapping the OLAP objects to relational database tables in a relational database using a mapping stored in an OLAP database; and grouping OLAP objects from the first expression and the second expression that are mapped to a same relational database table from the relational database tables; generating a relational query to retrieve the other report data to be used to respond to the first expression and the additional report data to be used to respond to the second expression from the relational database; executing the relational query to retrieve the other report data and the additional report data from the relational database; storing the other report data in the OLAP cache; using the other report data stored in the OLAP cache to respond to the first expression; and pre-loading the additional report data in the OLAP cache in anticipation of execution of the second expression; and subsequently executing the second expression by retrieving the additional report data to be used to respond to the second expression from the OLAP cache instead of from the relational database. - View Dependent Claims (2, 3, 4, 5, 6)
-
-
7. A computer program product, the computer program product comprising:
-
a non-transitory computer readable storage medium having computer readable program code embodied therewith, wherein, the computer readable program code, when executed by at least one processor of a computer, is configured to perform; generating an On-Line Analytical Processing (OLAP) query having a first expression for retrieving report data and other report data from an OLAP cache and a second expression for retrieving additional report data from the OLAP cache; executing the first expression to retrieve the report data that is stored in the OLAP cache to respond to the first expression; for the other report data that is not stored in the OLAP cache to respond to the first expression, identifying the other report data to be retrieved for the first expression and the additional report data to be retrieved for the second expression that is not stored in the OLAP cache by; identifying OLAP objects referenced in the first expression and the second expression; mapping the OLAP objects to relational database tables in a relational database using a mapping stored in an OLAP database; and grouping OLAP objects from the first expression and the second expression that are mapped to a same relational database table from the relational database tables; generating a relational query to retrieve the other report data to be used to respond to the first expression and the additional report data to be used to respond to the second expression from the relational database; executing the relational query to retrieve the other report data and the additional report data from the relational database; storing the other report data in the OLAP cache; using the other report data stored in the OLAP cache to respond to the first expression; and pre-loading the additional report data in the OLAP cache in anticipation of execution of the second expression; and subsequently executing the second expression by retrieving the additional report data to be used to respond to the second expression from the OLAP cache instead of from the relational database. - View Dependent Claims (8, 9, 10, 11, 12)
-
-
13. A computer system for augmenting a relational query, comprising:
-
a processor; and a storage device connected to the processor, wherein the storage device has stored thereon a program, and wherein the processor is configured to execute instructions of the program to perform operations, wherein the operations comprise; generating an On-Line Analytical Processing (OLAP) query having a first expression for retrieving report data and other report data from an OLAP cache and a second expression for retrieving additional report data from the OLAP cache; executing the first expression to retrieve the report data that is stored in the OLAP cache to respond to the first expression; for the other report data that is not stored in the OLAP cache to respond to the first expression, identifying the other report data to be retrieved for the first expression and the additional report data to be retrieved for the second expression that is not stored in the OLAP cache by; identifying OLAP objects referenced in the first expression and the second expression; mapping the OLAP objects to relational database tables in a relational database using a mapping stored in an OLAP database; and grouping OLAP objects from the first expression and the second expression that are mapped to a same relational database table from the relational database tables; generating a relational query to retrieve the other report data to be used to respond to the first expression and the additional report data to be used to respond to the second expression; executing the relational query to retrieve the other report data and the additional report data from the relational database; storing the other report data in the OLAP cache; using the other report data stored in the OLAP cache to respond to the first expression; and pre-loading the additional report data in the OLAP cache in anticipation of execution of the second expression; and subsequently executing the second expression by retrieving the additional report data to be used to respond to the second expression from the OLAP cache instead of from the relational database. - View Dependent Claims (14, 15, 16, 17, 18)
-
Specification