Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- mysql> explain SELECT * FROM user_test AS u1 LEFT OUTER JOIN user_test AS u2 ON u1.date_of_birth = u2.date_of_birth WHERE u1.first_name = 'cee' ;
- +----+-------------+-------+------+---------------------+---------------------+---------+---------------------------+------+-----------------------+
- | id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
- +----+-------------+-------+------+---------------------+---------------------+---------+---------------------------+------+-----------------------+
- | 1 | SIMPLE | u1 | ref | first_name_index | first_name_index | 152 | const | 44 | Using index condition |
- | 1 | SIMPLE | u2 | ref | date_of_birth_index | date_of_birth_index | 4 | rap_test.u1.date_of_birth | 9 | NULL |
- +----+-------------+-------+------+---------------------+---------------------+---------+---------------------------+------+-----------------------+
- 2 rows in set (0.00 sec)
Add Comment
Please, Sign In to add comment