planner: TIDB_INLJ
hint cannot take effect when left joining two sub-queries #46160
Closed
Description
Enhancement
create table t1 (a int, key(a));
create table t2 (a int, key(a));
explain select /*+ tidb_inlj(bb) */ aa.* from
(select * from t1) as aa
left join
(select t2.a, t2.a*2 as a2 from t2) as bb
on aa.a=bb.a;
mysql> show warnings;
+---------+------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| Level | Code | Message |
+---------+------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| Warning | 1815 | There are no matching table names for (bb) in optimizer hint /*+ INL_JOIN(bb) */ or /*+ TIDB_INLJ(bb) */. Maybe you can use the table alias name |
+---------+------+--------------------------------------------------------------------------------------------------------------------------------------------------+
1 row in set (0.00 sec)