Skip to content

Commit

Permalink
test(tianmu): add order by sentence in the mtr case various_join.test
Browse files Browse the repository at this point in the history
  • Loading branch information
Xinqiangxu authored and mergify[bot] committed Jun 16, 2023
1 parent f180323 commit 798ca7a
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
18 changes: 9 additions & 9 deletions mysql-test/suite/tianmu/r/various_join.result
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@ insert into t6 values (1, 2), (3, 4);
insert into t7 values (1, 3);
insert into t8 values (1, 3);
insert into t9 values (1, 2);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) order by t3.a;
a b a b a b
1 3 1 2 1 2
NULL NULL NULL NULL 2 3
NULL NULL NULL NULL 3 4
NULL NULL NULL NULL 4 5
NULL NULL NULL NULL 2 3
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) left join t4 on (t3.a = t4.a);
a b a b a b a b
1 3 1 2 1 2 1 3
Expand Down Expand Up @@ -61,18 +61,18 @@ NULL NULL NULL NULL 3 4
NULL NULL NULL NULL 4 5
NULL NULL NULL NULL 2 3
NULL NULL NULL NULL 1 2
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b and t3.a > t2.a and t3.a > t1.a);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b and t3.a > t2.a and t3.a > t1.a) order by t3.a;
a b a b a b
NULL NULL NULL NULL 1 2
NULL NULL NULL NULL 2 3
NULL NULL NULL NULL 3 4
NULL NULL NULL NULL 4 5
NULL NULL NULL NULL 2 3
NULL NULL NULL NULL 1 2
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b and t3.b > t2.a and t3.a < t1.b);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b and t3.b > t2.a and t3.a < t1.b) order by t3.a;
a b a b a b
1 3 1 2 1 2
NULL NULL NULL NULL 2 3
NULL NULL NULL NULL 3 4
NULL NULL NULL NULL 4 5
NULL NULL NULL NULL 2 3
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) left join t4 on (t3.a = t4.a and t2.a = t4.a) order by t3.a;
a b a b a b a b
1 3 1 2 1 2 1 3
Expand All @@ -82,12 +82,12 @@ NULL NULL NULL NULL 4 5 NULL NULL
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) right join t4 on (t3.a = t4.a and t2.a = t4.a) order by t3.a;
a b a b a b a b
1 3 1 2 1 2 1 3
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a) left join t4 on (t3.a = t4.a and t1.a = t4.a and t2.a = t4.a);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a) left join t4 on (t3.a = t4.a and t1.a = t4.a and t2.a = t4.a) order by t3.a;
a b a b a b a b
1 3 1 2 1 2 1 3
2 3 2 4 2 3 NULL NULL
NULL NULL NULL NULL 4 5 NULL NULL
NULL NULL NULL NULL 3 4 NULL NULL
NULL NULL NULL NULL 4 5 NULL NULL
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a) right join t4 on (t3.a = t4.a and t1.a = t4.a and t2.a = t4.a);
a b a b a b a b
1 3 1 2 1 2 1 3
Expand Down
8 changes: 4 additions & 4 deletions mysql-test/suite/tianmu/t/various_join.test
Original file line number Diff line number Diff line change
Expand Up @@ -32,22 +32,22 @@ insert into t7 values (1, 3);
insert into t8 values (1, 3);
insert into t9 values (1, 2);

select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) order by t3.a;
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) left join t4 on (t3.a = t4.a);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) where (t3.a = 1 or t3.a = 3);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) where (t3.a > 1);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t2.a = t3.a) left join t4 on (t3.a = t4.a and t1.b = t4.b) order by t3.a;
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t2.a = t3.a) left join t4 on (t3.a = t4.a and t2.b = t4.b) order by t3.a;
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b and t3.a > t1.a);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b and t3.a > t2.a and t3.a > t1.a);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b and t3.b > t2.a and t3.a < t1.b);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b and t3.a > t2.a and t3.a > t1.a) order by t3.a;
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b and t3.b > t2.a and t3.a < t1.b) order by t3.a;

# Below query is disabled until fixed #925
#select * from t1 left join t2 on (t1.a = t2.a) left join t3 on (t2.a = t3.a) left join t4 on (t4.a = t3.a) left join t5 on (t5.a = t2.a) left join t6 on (t5.a = t6.a and t6.a = t4.a);

select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) left join t4 on (t3.a = t4.a and t2.a = t4.a) order by t3.a;
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a and t2.b = t3.b) right join t4 on (t3.a = t4.a and t2.a = t4.a) order by t3.a;
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a) left join t4 on (t3.a = t4.a and t1.a = t4.a and t2.a = t4.a);
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a) left join t4 on (t3.a = t4.a and t1.a = t4.a and t2.a = t4.a) order by t3.a;
select * from t1 inner join t2 on (t1.a = t2.a) right join t3 on (t1.a = t3.a) right join t4 on (t3.a = t4.a and t1.a = t4.a and t2.a = t4.a);

# Below query is disabled until fixed #925
Expand Down

0 comments on commit 798ca7a

Please sign in to comment.