on-internet
← Community

Improve performance of a query with LEFT JOIN, 2 LIKE expressions,GROUP BY, and LIMIT

Stack Overflow ·

I am using codeigniter for an application where search needs to be performed i am using "Like" in the query for two tables. One table has data while other table has translations of it. So i need to search the string from both tables to get the result. Following is my query can any body make it more efficient. both tables has almost 10k records which may increase in future. If i am not joining the table then it works faster but with joining it takes long to give the results. $this->db->select('tbl2.translation_title as title,tbl1.id,tbl1.title as title'); $this->db->like('tbl1.title', $searchSt

Comments

Sign in or sign up to comment and upvote.

No comments yet.