×

Dynamic partition selection

  • US 9,652,496 B1
  • Filed: 06/25/2014
  • Issued: 05/16/2017
  • Est. Priority Date: 06/25/2014
  • Status: Active Grant
First Claim
Patent Images

1. A computer-implemented method comprising:

  • receiving a representation of a query plan generated for a query, the query plan comprising a first plurality of operators that, when executed by one or more computing nodes, cause the one or more computing nodes to compute a result for the query, wherein the query plan includes a dynamic scan operator that represents a first computing node obtaining tuples of one or more partitions of a table from storage and transferring the tuples to a second computing node that executes a parent operator of the dynamic scan operator;

    generating a partition selector operator corresponding to the dynamic scan operator, wherein the partition selector operator represents a third computing node that executes the partition selector operator including determining one or more partition identifiers of partitions of the table and transferring the one or more partition identifiers to the dynamic scan operator of the first computing node;

    determining a location in the query plan for the partition selector operator, including;

    determining, for each operator of a subset of operators in the query plan, whether the dynamic scan operator occurs in a subtree of the query plan that is rooted at the respective operator of the subset of operators; and

    determining, using results of the determinations of whether the dynamic scan operator occurs in a subtree of the query plan that is rooted at the respective operator of the subset of operators, a first operator in the query plan that is i) a parent operator of the partition selector operator and the dynamic scan operator or ii) a child operator of the partition selector operator;

    determining, using the first operator, the location in the query plan for the partition selector operator; and

    generating a modified query plan having the partition selector operator at the determined location, wherein the modified query plan includes a second plurality of operators that, when executed by one or more computing nodes, cause the one or more computing nodes to compute a result for the query.

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