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

Support map types in the Table / SQL API

    Details

    • Type: New Feature
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.3.0
    • Component/s: Table API & SQL
    • Labels:
      None

      Description

      This jira tracks the efforts of adding supports for maps into the Table / SQL APIs.

        Issue Links

          Activity

          Hide
          githubbot ASF GitHub Bot added a comment -

          GitHub user haohui opened a pull request:

          https://github.com/apache/flink/pull/3767

          FLINK-6377 [table] Support map types in the Table / SQL API

          This PR adds the supports of the map types in the Table / SQL API. It covers both the parsing and the runtime.

          One caveat is that users need to explicitly specify the map type. This is because the `TypeExtractor` is unable to infer the types because of the type erasure in Java. @StephanEwen and @twalthr can you please shed some lights on what is the best way to approach this? Comments are appreciated.

          You can merge this pull request into a Git repository by running:

          $ git pull https://github.com/haohui/flink FLINK-6377

          Alternatively you can review and apply these changes as the patch at:

          https://github.com/apache/flink/pull/3767.patch

          To close this pull request, make a commit to your master/trunk branch
          with (at least) the following in the commit message:

          This closes #3767


          commit 86397e2d6bd22473e1db5d91627d7e7e245e13cf
          Author: Haohui Mai <wheat9@apache.org>
          Date: 2017-04-25T06:12:29Z

          FLINK-6377 [table] Support map types in the Table / SQL API


          Show
          githubbot ASF GitHub Bot added a comment - GitHub user haohui opened a pull request: https://github.com/apache/flink/pull/3767 FLINK-6377 [table] Support map types in the Table / SQL API This PR adds the supports of the map types in the Table / SQL API. It covers both the parsing and the runtime. One caveat is that users need to explicitly specify the map type. This is because the `TypeExtractor` is unable to infer the types because of the type erasure in Java. @StephanEwen and @twalthr can you please shed some lights on what is the best way to approach this? Comments are appreciated. You can merge this pull request into a Git repository by running: $ git pull https://github.com/haohui/flink FLINK-6377 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/flink/pull/3767.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #3767 commit 86397e2d6bd22473e1db5d91627d7e7e245e13cf Author: Haohui Mai <wheat9@apache.org> Date: 2017-04-25T06:12:29Z FLINK-6377 [table] Support map types in the Table / SQL API
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user fhueske commented on a diff in the pull request:

          https://github.com/apache/flink/pull/3767#discussion_r113115187

          — Diff: flink-libraries/flink-table/src/test/java/org/apache/flink/table/api/java/batch/sql/SqlITCase.java —
          @@ -18,9 +18,15 @@

          package org.apache.flink.table.api.java.batch.sql;

          +import com.google.common.collect.ImmutableMap;
          — End diff –

          Can we use `java.util.Collections.singletonMap()` instead of Guava? We avoid using `Guava` due to version conflicts.

          Show
          githubbot ASF GitHub Bot added a comment - Github user fhueske commented on a diff in the pull request: https://github.com/apache/flink/pull/3767#discussion_r113115187 — Diff: flink-libraries/flink-table/src/test/java/org/apache/flink/table/api/java/batch/sql/SqlITCase.java — @@ -18,9 +18,15 @@ package org.apache.flink.table.api.java.batch.sql; +import com.google.common.collect.ImmutableMap; — End diff – Can we use `java.util.Collections.singletonMap()` instead of Guava? We avoid using `Guava` due to version conflicts.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user twalthr commented on the issue:

          https://github.com/apache/flink/pull/3767

          Thanks @haohui. I will add some more tests and merge this.

          Show
          githubbot ASF GitHub Bot added a comment - Github user twalthr commented on the issue: https://github.com/apache/flink/pull/3767 Thanks @haohui. I will add some more tests and merge this.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user asfgit closed the pull request at:

          https://github.com/apache/flink/pull/3767

          Show
          githubbot ASF GitHub Bot added a comment - Github user asfgit closed the pull request at: https://github.com/apache/flink/pull/3767
          Hide
          twalthr Timo Walther added a comment -

          Fixed in 1.3.0: 5b6e71ceb12d1fdf7d09d70744f3c0a8a4722768

          Show
          twalthr Timo Walther added a comment - Fixed in 1.3.0: 5b6e71ceb12d1fdf7d09d70744f3c0a8a4722768

            People

            • Assignee:
              wheat9 Haohui Mai
              Reporter:
              wheat9 Haohui Mai
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development