You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Wenchen Fan (Jira)" <ji...@apache.org> on 2025/04/13 12:54:00 UTC

[jira] [Assigned] (SPARK-51752) Enable rCTE referencing from within a CTE

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

Wenchen Fan reassigned SPARK-51752:
-----------------------------------

    Assignee: Pavle Martinović

> Enable rCTE referencing from within a CTE
> -----------------------------------------
>
>                 Key: SPARK-51752
>                 URL: https://issues.apache.org/jira/browse/SPARK-51752
>             Project: Spark
>          Issue Type: Sub-task
>          Components: SQL
>    Affects Versions: 4.1.0
>            Reporter: Pavle Martinović
>            Assignee: Pavle Martinović
>            Priority: Major
>              Labels: pull-request-available
>
> We should add the possibility for a recursion CTE to be referenced inside a (regular) CTE in the recursive part of the query. An example of one such query is the following:
> {{WITH RECURSIVE t1 AS (}}
> {{  SELECT 1 AS n}}
> {{  UNION ALL}}
> {{  WITH t2 AS }}{{(SELECT n + 1 FROM t1 WHERE n < 5)}}
> {{  SELECT * FROM t2}}
> {{) SELECT * FROM t1;}}
>  



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

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org