scarhand Posted February 11, 2011 Share Posted February 11, 2011 i have created an index on an ID column, however i need to create some type of index or find a solution for when i am searching a TEXT column for a LIKE its taking forever to execute the LIKE query on this text column because there are hundreds of thousands of rows. i dont think i can just create an index on it, can i? what is the proper way to optimize this? Quote Link to comment https://forums.phpfreaks.com/topic/227329-indexing-a-text-column/ Share on other sites More sharing options...
bh Posted February 11, 2011 Share Posted February 11, 2011 Hi, if your table type is MyIsam you can use FULLTEXT index search. If its an InnoDB you can use prefixed index on your text column. Example you create a 20 character length index. Quote Link to comment https://forums.phpfreaks.com/topic/227329-indexing-a-text-column/#findComment-1172657 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.