You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Daniel (Jira)" <ji...@apache.org> on 2025/01/08 21:14:00 UTC
[jira] [Updated] (SPARK-50772) Retain table aliases after SET, EXTEND, DROP operators
[ https://issues.apache.org/jira/browse/SPARK-50772?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Daniel updated SPARK-50772:
---------------------------
Description:
Per initial feedback from testing, users would like table aliases (such as those mapping to left and right side inputs to a prior join) to remain available after SET, DROP, and EXTEND operators. Here is an example that should work:
{{values (0), (1) lhs(a)}}
{{|> inner join values (1), (2) rhs(a) using (a)}}
{{|> extend lhs.a + rhs.a as z1}}
{{|> extend lhs.a - rhs.a as z2}}
{{|> drop z1}}
{{|> where z2 = 0}}
{{|> order by lhs.a, rhs.a, z2}}
{{|> set z2 = 4}}
{{|> limit 2}}
{{|> select lhs.a, rhs.a, z2;}}
1 1 4
was:
Per initial feedback from testing, users would like table aliases (such as those mapping to left and right side inputs to a prior join) to remain available after SET, DROP, and EXTEND operators. Here is an example that should work:
{{values (0), (1) lhs(a)}}
{{|> inner join values (1), (2) rhs(a) using (a)}}
{{|> extend lhs.a + rhs.a as z1}}
{{|> extend lhs.a - rhs.a as z2}}
{{|> drop z1}}
{{|> where z2 = 0}}
{{|> order by lhs.a, rhs.a, z2}}
{{|> set z2 = 4}}
{{|> limit 2}}
{{|> select lhs.a, rhs.a, z2;}}
> Retain table aliases after SET, EXTEND, DROP operators
> ------------------------------------------------------
>
> Key: SPARK-50772
> URL: https://issues.apache.org/jira/browse/SPARK-50772
> Project: Spark
> Issue Type: Sub-task
> Components: SQL
> Affects Versions: 4.0.0
> Reporter: Daniel
> Priority: Major
>
> Per initial feedback from testing, users would like table aliases (such as those mapping to left and right side inputs to a prior join) to remain available after SET, DROP, and EXTEND operators. Here is an example that should work:
>
> {{values (0), (1) lhs(a)}}
> {{|> inner join values (1), (2) rhs(a) using (a)}}
> {{|> extend lhs.a + rhs.a as z1}}
> {{|> extend lhs.a - rhs.a as z2}}
> {{|> drop z1}}
> {{|> where z2 = 0}}
> {{|> order by lhs.a, rhs.a, z2}}
> {{|> set z2 = 4}}
> {{|> limit 2}}
> {{|> select lhs.a, rhs.a, z2;}}
>
> 1 1 4
--
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