Distributed execution of expressions in a query
First Claim
1. A system for executing a query specification, comprising:
- a first computing device having a processor and a memory;
wherein the memory stores instructions operable by the processor to;
evaluate, during conversion of a query specification to a locally-executable query, the query specification to identify an expression in the query specification as a candidate expression to be executed by a second computing device hosting a source of data specified in the candidate expression, wherein the conversion is performed by the first computing device and wherein the locally-executable query is executable by the first computing device against the source of data hosted on the second computing device;
determine a cost estimate of executing the candidate expression at the first computing device;
determine whether the cost estimate of executing the candidate expression at the first computing device is greater than a threshold; and
replace, in response to determining that the cost estimate does exceed thethreshold, the candidate expression with a native query function, wherein the native query function is wrapped with metadata that represents a dimensionality of returning results indicative of level member hierarchies that will be included in a result of the native query function and wherein the native query is wrapped with a value indicative of the requirement to inject a context parameter.
1 Assignment
0 Petitions
Accused Products
Abstract
A computer-implemented method for executing a query specification can include evaluating the query specification by a first computing device to identify a candidate expression in the query specification to be executed by a second computing device hosting a source of data specified in the candidate expression. A cost estimate for executing the candidate expression at the first computing device is determined. Whether the cost estimate of executing the candidate expression at the first computing device is greater than a threshold is determined. The candidate expression is replaced with a native query function when the cost estimate of executing the candidate expression at the first computing device is greater than the threshold. The native query function can be executed at the second computing device. It can be determined whether a runtime context is necessary, and if necessary, a context parameter is injected into the native query function.
-
Citations
13 Claims
-
1. A system for executing a query specification, comprising:
-
a first computing device having a processor and a memory; wherein the memory stores instructions operable by the processor to; evaluate, during conversion of a query specification to a locally-executable query, the query specification to identify an expression in the query specification as a candidate expression to be executed by a second computing device hosting a source of data specified in the candidate expression, wherein the conversion is performed by the first computing device and wherein the locally-executable query is executable by the first computing device against the source of data hosted on the second computing device;
determine a cost estimate of executing the candidate expression at the first computing device;determine whether the cost estimate of executing the candidate expression at the first computing device is greater than a threshold; and
replace, in response to determining that the cost estimate does exceed thethreshold, the candidate expression with a native query function, wherein the native query function is wrapped with metadata that represents a dimensionality of returning results indicative of level member hierarchies that will be included in a result of the native query function and wherein the native query is wrapped with a value indicative of the requirement to inject a context parameter. - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
-
8. A computer program product for executing a query specification, the computer program product comprising a computer readable storage medium having program code embodied therewith, the program code comprising computer readable program code configured for:
-
evaluating, by a first computing device configured to transform query specifications into queries for execution by the first computing device solely against databases hosted on other computing devices, a first query specification to identify at least one expression of a set of expressions as a candidate expression to be executed by a second computing device hosting a source of data specified in the candidate expression, the evaluation based on rules stored in a memory of the first computing device; determining a cost estimate of executing the candidate expression at the first computing device; determining whether the cost estimate of executing the candidate expression at the first computing device is greater than a threshold; and replacing the candidate expression with a native query function when the cost estimate of executing the candidate expression at the first computing device is greater than the threshold, wherein the native query function is wrapped with a value indicative of the requirement to inject a context parameter and wherein the native query is wrapped with metadata that represents a dimensionality of returning results indicative of level member hierarchies that will be included in a result of the native query function. - View Dependent Claims (9, 10, 11, 12)
-
-
13. A computer program product for executing a query specification, the computer program product comprising a computer readable storage medium having program code embodied therewith, the program code comprising computer readable program code configured for:
-
evaluating, by a first computing device, a first query specification to identify at least one expression of a set of expressions as a candidate expression to be executed by a second computing device hosting a source of data specified in the candidate expression, the evaluation based on rules stored in a memory of the first computing device; determining a cost estimate of executing the candidate expression at the first computing device; determining whether the cost estimate of executing the candidate expression at the first computing device is greater than a threshold; and replacing the candidate expression with a native query function when the cost estimate of executing the candidate expression at the first computing device is greater than the threshold, wherein the native query function is wrapped with a value indicative of the requirement to inject a context parameter and wherein the native query is wrapped with metadata that represents a dimensionality of returning results indicative of level member hierarchies that will be included in a result of the native query function.
-
Specification