Class ResultSetPicker

  • All Implemented Interfaces:
    ResultSetProvider, ResultSetProvider.Large

    public class ResultSetPicker
    extends Object
    implements ResultSetProvider.Large
    An adapter class used internally when a set-returning user function returns a ResultSetHandle, presenting it as a ResultSetProvider instead.

    Note on the current implementation: this class operates by fetching every field of every row of the result set as a Java object via the one-argument getObject, then storing it into the writable result set supplied by PL/Java. Apart from being rather inefficient, this can involve conversions through legacy types (such as java.sql.Timestamp when the JSR 310 java.time conversions are better specified). In cases where that isn't acceptable, the user function should be declared to return ResultSetProvider and do this work itself.