Patent ID: 7873627
Filing Date: 2011-01-18
Classification: G06F

Abstract:
1. A computer-implemented method to optimize a query plan, the method comprising: receiving a query for processing by a database application that is executed by a hardware processor system of a computer system to perform acts for processing the query and retrieving data from a computer readable storage medium, wherein processing the query comprises acts of: creating a query plan from said query, the query plan comprising a plurality of subqueries; identifying at least two subqueries of said query plan that are directed towards a same data set, the at least two subqueries comprising a first subquery that requests first data from said data set, and a second subquery that requests second data from said data set; generating a new subquery that comprises a predicate that is a disjunction of all predicates of the first and second subquery in the query plan, wherein direction toward the same data set is the sole requirement to generating the new subquery; and replacing said first and second subqueries in said query plan with the new subquery for querying the data set for both said first data and said second data so that the data set is accessed only once for all identified subqueries.