×

Query transformation for union all view join queries using join predicates for pruning and distribution

  • US 7,188,098 B2
  • Filed: 09/24/2003
  • Issued: 03/06/2007
  • Est. Priority Date: 09/24/2003
  • Status: Active Grant
First Claim
Patent Images

1. A method of optimizing a query in a computer system, the query being performed by the computer system to retrieve data from a database stored on the computer system, the method comprising:

  • (a) combining join predicates from a query with local predicates from each branch of one or more UNION ALL views referenced by the query, wherein the query joins two or more of the UNION ALL views, each UNION ALL view contains a UNION ALL of one base table with a local predicate specifying a data range in the base table, and the join predicates are on columns of the UNION ALL views that correspond to the local predicates;

    (b) analyzing the combined predicates; and

    (c) generating a join, except when the analyzing step indicates that the combined predicates are always FALSE and the join generates an empty result.

View all claims
  • 2 Assignments
Timeline View
Assignment View
    ×
    ×