I have a custom table in my database with approximately 900 000 rows. I am running this query:
$products = Mage::getModel("similar/flipkart")->getCollection()->addFieldToFilter('title', array('like' => '%'.$query.'%')) ->setCurPage(1)
->setPageSize(4);
This query takes more than 12 seconds to return result. However when I run limit query on mysql table, I get result instantaneously. How do I speed up my process. When logged the query, I got this:
`SELECT main_table.* FROM flipkart_furn AS main_table WHERE (title LIKE '%chai%')`
So basically limit did not append to it. How do i make limit gets appended to it