tags:

views:

9

answers:

0

I'm having an issue working out how to identify specific movie titles, when extra information is included after the title itself.

At the moment, I have a title such as:

Sherlock Holmes [2010]

In the database it's something like:

Sherlock Holmes (2010)

or just

Sherlock Holmes

Currently I'm matching it by stripping off any square brackets and the content of the square brackets, to leave the title, then using this SQL:

SELECT * FROM movie_table WHERE full_title LIKE '$search_title%'

The problem is that this produces a false positive for the movie "Sherlock".

Any idea how to better handle this?