bug 1430034 TMUDF: processData() fails to handle several data type bug 1430438 TMUDF: A TMUDF with nonexisting external name crashes sqlci with a core bug 1430453 TMUDF: A TMUDF missing 'language cpp' crashes sqlci with a core bug 1430484 TMUDF: User defined error number for UDRException() not returned at run time bug 1404053 Core with SIGSEGV during CREATE PROCEDURE statement when procedure validation fails
Summary of changes:
- Support for more data types, including char types with character set UCS2 and interval types. Unlike in other types of UDFs, intervals are represented as integers, but that representation is not directly exposed to the UDF writer. CLOBs and BLOBs are only supported when they are mapped to VARCHARS. - Support to get and set values by specifying a C++ data type of time_t for datetime and certain interval values. - The default language for creating UDFs is changing. It used to be C, the new rule depends on the type of the library. If we can determine the library to be a jar file, the default language is Java. For other libraries, the default is C for scalar UDFs, C++ for table-valued UDFs. Also the PARAMETER STYLE clause is no longer used for TMUDFs, the parameter style is computed automatically for now. PARAMETER STYLE is now optional for Java stored procedures. - Error handling is somewhat improved, fewer internal errors occur when a UDR raises an exception. Still needs work. - Making interfaces of OrderInfo and PartitionInfo more similar by giving them similar methods.
Normalizer interface for TMUDFs, blueprint cmp-tmudf-compile-time-interface Added new compiler interfaces:
describeParamsAndColumns has been extended to allow updating PARTITION BY and ORDER BY clauses specified for input tables.
describeDataFlowAndPredicates() allows the TMUDF to eliminate columns not needed by the query and to push predicates into the TMUDF or to the children.
describeConstraints() allows the TMUDF to see cardinality and uniqueness constraints of the table-valued inputs (children) and to synthesize cardinality and uniqueness constraints on the TMUDF result.
TMUDFs now have 3 function types: GENERIC - makes most conservative assumptions in the compiler MAPPER - assumes TMUDF carries no state between input rows REDUCER - assumes TMUDF carries no state between input partitions defined by PARTITION BY clause
Query id and user id are now available to the UDR.
Added doxygen documentation for the C++ UDR interface. The resulting web page will be published on the wiki. To generate the documentation yourself, do the following:
cd $MY_SQROOT/../sql/sqludr doxygen doxygen_tmudr.1.6.config # now open tmudr_1.0/html/index.html in a web browser