You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Support for common table expressions (aka WITH) via special LINQ operator #26486
Reacted by Albert Ragány-Németh, Massimiliano Donini, Steven Rasmussen, JohnEffo, sidneyxvr, levyhnunes, LucasLima, matt beary, Volodymyr Rets, Jan Jones and 127 more
Reacted by netotz, Denis Zimin, Viesturs Priedītis, Milo, Miguel Oliveira, Joona Luoma, Sujan Sapkota, Yimmy Quispe Yujra, David Thompson, Fabien Ménager and 10 more
changed the title [-]Support for common table expressions (aka WITH)[/-][+]Support for common table expressions (aka WITH) using LINQ[/+]on Oct 28, 2021
changed the title [-]Support for common table expressions (aka WITH) using LINQ[/-][+]Support for common table expressions (aka WITH) by translating LINQ query[/+]on Oct 28, 2021
changed the title [-]Support for common table expressions (aka WITH) by translating LINQ query[/-][+]Support for common table expressions (aka WITH) via special LINQ operator[/+]on Apr 25, 2023
Note: all databases - except SQL Server - support embedding CTEs within arbitrary subqueries inside the query;
SELECT*FROM (WITH t AS (SELECT1) SELECT*FROM t) AS foo;
This effectively makes CTEs an optional prefix of SelectExpression.
In addition, SQL Server (but not other databases) requires that column names be explicitly specified when they're not named within the subquery:
WITH t AS (SELECT1AS q) SELECT*FROM t; -- Column name bubbles out of the subquery
WITH t (q) AS (SELECT1) SELECT*FROM t; -- Column explicitly specified as part of the CTE syntax
WITH t AS (SELECT1) SELECT*FROM t; -- Fails in SQL Server, works elsewhere (with unknown column name)
Reacted by Carlos Martos, Miguel Oliveira, Joona Luoma, David Rettenbacher and zejji
@ajcvickers and @roji
I hope CTEs and window functions #12747 will be added to 10.0 milestone for boost performance of advanced queries with grouping and aggregation.
Reacted by Miguel Oliveira, Kostiantyn Nesterenko, zejji, Hicham el Allouchi, Mauricio Dominguez, Christian Nagel, David Drápela, Jeremy Salwen, Jay Chu, Manuel Moser and 14 more
+1 this would be great to see and would benefit us across a number of projects
Reacted by Carlos Martos, Miguel Oliveira, zejji, Hicham el Allouchi, Mattia Ricci, jaglick, yair-legit, Jannes Ströhlein, David Drápela, Jeremy Salwen and 21 more
Activity
[-]Support for common table expressions (aka WITH)[/-][+]Support for common table expressions (aka WITH) using LINQ[/+][-]Support for common table expressions (aka WITH) using LINQ[/-][+]Support for common table expressions (aka WITH) by translating LINQ query[/+]roji commentedon Dec 19, 2021
Note: all major databases support prefixing UPDATE/DELETE with CTEs (see #795 for bulk updates).
[-]Support for common table expressions (aka WITH) by translating LINQ query[/-][+]Support for common table expressions (aka WITH) via special LINQ operator[/+]roji commentedon Aug 27, 2023
Note: all databases - except SQL Server - support embedding CTEs within arbitrary subqueries inside the query;
This effectively makes CTEs an optional prefix of SelectExpression.
In addition, SQL Server (but not other databases) requires that column names be explicitly specified when they're not named within the subquery:
mojtabakaviani commentedon Nov 23, 2024
@ajcvickers and @roji
I hope CTEs and window functions #12747 will be added to 10.0 milestone for boost performance of advanced queries with grouping and aggregation.
Pepsi1x1 commentedon Dec 6, 2024
+1 this would be great to see and would benefit us across a number of projects