I have a problem. I want to fetch last 10 rows of two table (live_st and load_balace) joined together that have an ip ending with 134. both table have millions of data.
I tried this query in mysql :
SELECT live_stats.domain_name
FROM live_stats JOIN load_balance
ON live_stats.user_id=load_balance.unique_id
WHERE load_balance.ip_address like '%134'
ORDER BY live_stats.created desc limit 10;
its worked but too slow . is there any way to speed up the query; thanks for advance;