diff --git a/ibis/backends/tests/snapshots/test_generic/test_many_subqueries/snowflake/out.sql b/ibis/backends/tests/snapshots/test_generic/test_many_subqueries/snowflake/out.sql index c2670a045cce..a392157a4412 100644 --- a/ibis/backends/tests/snapshots/test_generic/test_many_subqueries/snowflake/out.sql +++ b/ibis/backends/tests/snapshots/test_generic/test_many_subqueries/snowflake/out.sql @@ -1,42 +1,32 @@ -WITH "t6" AS ( +WITH "t1" AS ( SELECT - "t5"."street", - ROW_NUMBER() OVER (ORDER BY "t5"."street" ASC) - 1 AS "key" + "t0"."street", + ROW_NUMBER() OVER (ORDER BY "t0"."street" ASC) - 1 AS "key" + FROM "data" AS "t0" +), "t7" AS ( + SELECT + "t6"."street", + ROW_NUMBER() OVER (ORDER BY "t6"."street" ASC) - 1 AS "key" FROM ( SELECT - "t2"."street", - "t2"."key" - FROM ( - SELECT - "t0"."street", - ROW_NUMBER() OVER (ORDER BY "t0"."street" ASC) - 1 AS "key" - FROM "data" AS "t0" - ) AS "t2" + "t3"."street", + "t3"."key" + FROM "t1" AS "t3" INNER JOIN ( SELECT - "t1"."key" - FROM ( - SELECT - "t0"."street", - ROW_NUMBER() OVER (ORDER BY "t0"."street" ASC) - 1 AS "key" - FROM "data" AS "t0" - ) AS "t1" - ) AS "t4" - ON "t2"."key" = "t4"."key" - ) AS "t5" -), "t1" AS ( - SELECT - "t0"."street", - ROW_NUMBER() OVER (ORDER BY "t0"."street" ASC) - 1 AS "key" - FROM "data" AS "t0" + "t2"."key" + FROM "t1" AS "t2" + ) AS "t5" + ON "t3"."key" = "t5"."key" + ) AS "t6" ) SELECT - "t8"."street", - "t8"."key" -FROM "t6" AS "t8" + "t9"."street", + "t9"."key" +FROM "t7" AS "t9" INNER JOIN ( SELECT - "t7"."key" - FROM "t6" AS "t7" -) AS "t10" - ON "t8"."key" = "t10"."key" \ No newline at end of file + "t8"."key" + FROM "t7" AS "t8" +) AS "t11" + ON "t9"."key" = "t11"."key" \ No newline at end of file