Skip to content

Commit 9979526

Browse files
authored
Merge pull request #3250 from dolthub/angela/subquery_optimization
Replace SubqueryAlias that selects an entire table with TableAlias
2 parents 8999cb4 + e103263 commit 9979526

File tree

9 files changed

+1489
-1827
lines changed

9 files changed

+1489
-1827
lines changed

enginetest/enginetests.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4915,10 +4915,6 @@ func TestSessionSelectLimit(t *testing.T, harness Harness) {
49154915
Query: "select count(*), y from (select y from a) b group by y;",
49164916
Expected: []sql.Row{{2, 1}, {3, 2}},
49174917
},
4918-
{
4919-
Query: "select count(*), y from (select y from a) b group by y;",
4920-
Expected: []sql.Row{{2, 1}, {3, 2}},
4921-
},
49224918
{
49234919
Query: "with b as (select y from a order by x) select * from b",
49244920
Expected: []sql.Row{{1}, {1}},

enginetest/join_planning_tests.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1801,12 +1801,12 @@ join uv d on d.u = c.x`,
18011801
tests: []JoinPlanTest{
18021802
{
18031803
q: "select * from t1 cross join t2 join (select * from t3) v3 on v3.k = t2.j;",
1804-
types: []plan.JoinType{plan.JoinTypeHash, plan.JoinTypeCross},
1804+
types: []plan.JoinType{plan.JoinTypeCross, plan.JoinTypeInner},
18051805
exp: []sql.Row{},
18061806
},
18071807
{
18081808
q: "select * from t1 cross join t2 join (select * from t3) v3 on v3.k >= t2.j order by i, j, k;",
1809-
types: []plan.JoinType{plan.JoinTypeInner, plan.JoinTypeCross},
1809+
types: []plan.JoinType{plan.JoinTypeCross, plan.JoinTypeInner},
18101810
exp: []sql.Row{
18111811
{1, 1, 3},
18121812
{1, 2, 3},

enginetest/queries/integration_plans.go

Lines changed: 1011 additions & 1037 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)