You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Dmitry Sysolyatin (Jira)" <ji...@apache.org> on 2023/04/06 08:49:00 UTC

[jira] [Updated] (CALCITE-5633) Allow table functions to be inside select list

     [ https://issues.apache.org/jira/browse/CALCITE-5633?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dmitry Sysolyatin updated CALCITE-5633:
---------------------------------------
    Component/s: core

> Allow table functions to be inside select list
> ----------------------------------------------
>
>                 Key: CALCITE-5633
>                 URL: https://issues.apache.org/jira/browse/CALCITE-5633
>             Project: Calcite
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 1.34.0
>            Reporter: Dmitry Sysolyatin
>            Priority: Major
>
> Currently, it is impossible to use table functions inside select list.
> For example:
> {code}
> SELECT UNNEST(ARRAY[1,2,3]);
> {code}
> {code}
> SELECT table(generate_series(1,2)); // generate_series is user defined table function
> {code}
> Engines like PostgreSQL support it[1]:
> {quote}Functions returning sets can also be called in the select list of a query. For each row that the query generates by itself, the set-returning function is invoked, and an output row is generated for each element of the function's result set
> {quote}
> [1] https://www.postgresql.org/docs/current/xfunc-sql.html



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