When I execute the following query:
SELECT * FROM `table1` INNER JOIN table2 ON table2.number = table1.number
I get the result within 2 s
Instead of this you can use this method:
SELECT * FROM `table1` LEFT JOIN table2 ON table2.number = table1.number WHERE table2.number is NULL OR table1.number is NULL