What is the best way to implement a substring search in SQL?
问题 We have a simple SQL problem here. In a varchar column, we wanted to search for a string anywhere in the field. What is the best way to implement this for performance? Obviously an index is not going to help here, any other tricks? We are using MySQL and have about 3 million records. We need to execute many of these queries per second so really trying to implement these with the best performance. The most simple way to do this is so far is: Select * from table where column like '%search%' I