Github user tonycox commented on the issue:

    https://github.com/apache/flink/pull/3127
  
    I think all it's just a syntax sugar
    ```scala
          val data = List(
            Row.of(Row.of("data_1", "dob"), Row.of("info_4", "dub")),
            Row.of(Row.of("data_1", "dob"), Row.of("info_4", "dub")),
            Row.of(Row.of("data_1", "dob"), Row.of("info_4", "dub")))
    
          val info= RowTypeInfo.from(
            RowTypeInfo.from(classOf[String], classOf[String]),
            RowTypeInfo.from(classOf[String], classOf[String])
          )
    
          execEnv.fromCollection(data, info)
    ```
    instead of
    ```scala
          val info = new RowTypeInfo(
            Array[TypeInformation[_]](
              new RowTypeInfo(
                Array[TypeInformation[_]](
                  BasicTypeInfo.STRING_TYPE_INFO,
                  BasicTypeInfo.STRING_TYPE_INFO),
                Array("name", "age")),
              new RowTypeInfo(
                Array[TypeInformation[_]](
                  BasicTypeInfo.STRING_TYPE_INFO,
                  BasicTypeInfo.STRING_TYPE_INFO),
                Array("more_info", "and_so_on"))),
            Array("person", "additional")
          )
    
          execEnv.fromCollection(data, info)
    ```


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to