You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "jackylau (Jira)" <ji...@apache.org> on 2023/04/20 10:56:00 UTC

[jira] [Commented] (FLINK-31677) Add MAP_ENTRIES supported in SQL & Table API

    [ https://issues.apache.org/jira/browse/FLINK-31677?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17714539#comment-17714539 ] 

jackylau commented on FLINK-31677:
----------------------------------

hi [~Sergey Nuyanzin] do you have time to review it ?

 

> Add MAP_ENTRIES supported in SQL & Table API
> --------------------------------------------
>
>                 Key: FLINK-31677
>                 URL: https://issues.apache.org/jira/browse/FLINK-31677
>             Project: Flink
>          Issue Type: Improvement
>          Components: Table SQL / Planner
>    Affects Versions: 1.18.0
>            Reporter: jackylau
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 1.18.0
>
>
> map_entries(map) - Returns an unordered array of all entries in the given map.
> Syntax:
> map_entries(map)
> Arguments:
> map: An MAP to be handled.
> Returns:
> Returns an unordered array of all entries in the given map.
> Returns null if the argument is null
> {code:sql}
> > SELECT map_entries(map[1, 'a', 2, 'b']);
>  [(1,"a"),(2,"b")]{code}
> See also
> presto [https://prestodb.io/docs/current/functions/map.html]
> spark https://spark.apache.org/docs/latest/api/sql/index.html#map_entries



--
This message was sent by Atlassian Jira
(v8.20.10#820010)