DECORRELATION OF USER-DEFINED FUNCTION INVOCATIONS IN QUERIES
First Claim
1. A computer-implemented method for transforming user-defined-function invocations within a query-based environment, the method comprising:
- receiving a query with a user-defined-function (UDF);
parsing the UDF into a plurality of statements;
constructing a first expression tree representation of the UDF;
constructing a second expression tree representation of the query absent the UDF;
generating a transformed expression representation of the query by merging the first expression tree and the second expression tree based on parameters of the first expression tree and attributes of the second expression tree; and
simplifying the transformed expression using transformation rules, based on a determination that the transformed expression can be simplified.
2 Assignments
0 Petitions
Accused Products
Abstract
Systems, methods, and computer-readable medium, are disclosed for transforming user-defined-function invocations in a query-based environment. A user-defined-function (UDF) and a query invoking the UDF are received. The UDF is parsed into a plurality of statements. A first expression tree corresponding to the UDF and a second expression tree corresponding the query are constructed, and merged using an operator to generate a transformed expression. The transformed expression is simplified, using transformation rules, if it is determined that is can be simplified.
-
Citations
20 Claims
-
1. A computer-implemented method for transforming user-defined-function invocations within a query-based environment, the method comprising:
-
receiving a query with a user-defined-function (UDF); parsing the UDF into a plurality of statements; constructing a first expression tree representation of the UDF; constructing a second expression tree representation of the query absent the UDF; generating a transformed expression representation of the query by merging the first expression tree and the second expression tree based on parameters of the first expression tree and attributes of the second expression tree; and simplifying the transformed expression using transformation rules, based on a determination that the transformed expression can be simplified. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10)
-
-
11. A system for transforming user-defined-function invocations within a query-based environment, the system comprising:
-
a parser module configured to; receive a query with a user-defined-function (UDF); and parse the UDF into a plurality of statements; a processor-implemented tree-construction module configured to; construct a first expression tree representation of the UDF; and construct a second expression tree representation of the query absent the UDF; and a transformer module configured to; generate a transformed expression representation of the query by merging the first expression tree and the second expression tree based on parameters of the first expression tree and attributes of the second expression tree; and simplify the transformed expression using transformation rules, based on a determination that the transformed expression can be simplified. - View Dependent Claims (12, 13, 14, 15, 16)
-
-
17. A non-transitory computer-readable storage device configured to store instructions executable by a processing device, wherein execution of the instructions in a query-based environment causes the processing device to implement a method of transforming a user-defined-function invocations within the query-based environment comprising:
-
receiving a query with a user-defined-function (UDF); parsing the UDF into a plurality of statements; constructing a first expression tree representation of the UDF; constructing a second expression tree representation of the query absent the UDF; generating a transformed expression representation of the query by merging the first expression tree and the second expression tree based on parameters of the first expression tree and attributes of the second expression tree; and simplifying the transformed expression using transformation rules, based on a determination that the transformed expression can be simplified. - View Dependent Claims (18, 19, 20)
-
Specification