Patent ID: 8126872

Claim:
A method for estimating a cardinality resulting from the application of one or more partially applied predicates against a range-partitioned table of a database, the method comprising: identifying at least one key column, wherein the at least one key column at least partially defines one or more data partitions in the range-partitioned table; calculating at least one combination of partially applicable predicates; calculating partial selectivities for the at least one combination of partially applicable predicates; computing, by a processor, an estimated cardinality based on the partial selectivities; determining a Query Execution Plan (QEP) based on the estimated cardinality; and accessing the range-partitioned table in the database based on a plan specified by the QEP, wherein the at least one combination of partially applicable predicates includes a partition of the range-partitioned table that satisfies the at least one combination of partially applicable predicates in estimating the cardinality, and the at least one combination of partially applicable predicates excludes other partitions of the range-partitioned table that do not satisfy the at least one combination of partially applicable predicates.