Class UnnestRowsWithOrdinalityFunction

  • All Implemented Interfaces:
    org.apache.flink.table.functions.FunctionDefinition, org.apache.flink.table.functions.SpecializedFunction

    @Internal
    public class UnnestRowsWithOrdinalityFunction
    extends UnnestRowsFunctionBase
    Flattens ARRAY, MAP, and MULTISET using a table function and adds one extra column with the position of the element. It does this by another level of specialization using a subclass of UnnestRowsFunctionBase.UnnestTableFunctionBase.
    • Constructor Detail

      • UnnestRowsWithOrdinalityFunction

        public UnnestRowsWithOrdinalityFunction()
    • Method Detail

      • createCollectionUnnestFunction

        protected org.apache.flink.table.functions.UserDefinedFunction createCollectionUnnestFunction​(org.apache.flink.table.functions.SpecializedFunction.SpecializedContext context,
                                                                                                      org.apache.flink.table.types.logical.LogicalType elementType,
                                                                                                      org.apache.flink.table.data.ArrayData.ElementGetter elementGetter)
        Specified by:
        createCollectionUnnestFunction in class UnnestRowsFunctionBase
      • createMapUnnestFunction

        protected org.apache.flink.table.functions.UserDefinedFunction createMapUnnestFunction​(org.apache.flink.table.functions.SpecializedFunction.SpecializedContext context,
                                                                                               org.apache.flink.table.types.logical.RowType keyValTypes,
                                                                                               org.apache.flink.table.data.ArrayData.ElementGetter keyGetter,
                                                                                               org.apache.flink.table.data.ArrayData.ElementGetter valueGetter)
        Specified by:
        createMapUnnestFunction in class UnnestRowsFunctionBase