Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-15610

How to achieve the udf that the number of return column is uncertain

    XMLWordPrintableJSON

    Details

    • Type: Wish
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Table SQL / API
    • Labels:
      None

      Description

      For example:https://help.aliyun.com/knowledge_detail/98948.html?spm=a2c4g.11186631.2.3.21b81761QhpBte

       

      
      SELECT c1, c2 
      FROM T1, lateral table(MULTI_KEYVALUE(str, split1, split2, key1, key2)) 
      as T(c1, c2)
      
      
      SELECT c1, c2, c3 
      FROM T1, lateral table(MULTI_KEYVALUE(str, split1, split2, key1, key2, key3)) 
      as T(c1, c2, c3)
      
      

      For Tablefunction:

      
      public TypeInformation<Row> getResultType() {
        return Types.ROW(Types.STRING(),Types.STRING());
      }
      
      

      The retrun type of  `getResultType` is `TypeInformation<Row>`,i want to achieve the size of row is not fixed.

       

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              hehuiyuan hehuiyuan
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated: