×

Method for aggregation subquery join elimination

  • US 7,454,416 B2
  • Filed: 04/30/2003
  • Issued: 11/18/2008
  • Est. Priority Date: 04/30/2003
  • Status: Expired due to Fees
First Claim
Patent Images

1. A computer implemented method for transforming a database statement containing a first subquery and a second subquery joined to the first subquery, the first subquery including a GROUP BY operation over a child subquery, the method comprising:

  • removing the first subquery from the database statement thereby eliminating the JOIN between the first subquery and the second subquery,wherein removal of the first subquery and elimination of the JOIN between the first subquery and the second subquery creates a transformed database statement that includes the second subquery and excludes the first subquery, andwhereinthe child subquery subsumes the second subquery,the child subquery is equivalent to the second subquery when a GROUP BY compensation operation is applied to the child subquery,a plurality of columns in the GROUP BY compensation operation is a super set of one or more columns in the GROUP BY operation,the JOIN between the first subquery and the second subquery involves an equality predicate between at least one column in the GROUP BY operation and at least one column in the GROUP BY compensation operation,one or more aggregation functions in the first subquery are not referenced elsewhere in the database statement, andthe first subquery does not include a local predicate on the GROUP BY operation.

View all claims
  • 1 Assignment
Timeline View
Assignment View
    ×
    ×