Patent ID: 7577637

Claim:
A computer-implemented method for managing compilation of a database statement that includes a user-defined table function that requires partitioning of data input to the user-defined table function, the method comprising: while generating an execution plan for the database statement, determining whether a partitioning of output data from an operation that feeds the user-defined table function is compatible with the partitioning required by the user-defined table function; and if partitioning of the output data from the operation that feeds the user-defined table function is compatible with the partitioning required by the user-defined table function, then specifying, in the execution plan, execution of both the operation that feeds the user-defined table function and the user-defined table function by a same set of processes; wherein the user-defined table function is a non-native function that has been registered with a database system that manages compilation of the database statement; wherein the partitioning required by the user-defined table function is specified in a function definition corresponding to the user-defined table function; and wherein the method is performed by one or more computing devices.