I am coding OSMDb excercises in the Training course.
In Movies screen, I have a search button, it allows search the Movies by Title or PlotSummary.
When I enter '%' or '_' to the search input, and click button search, the results always are all the records in the database.
In Agg, in Filters tab I have a filter:
Movie.Title like "%" + SearchText + "%" or Movie.PlotSummary like "%" + SearchText + "%"
How can I do to only search the movie, which has Title or PlotSummary contain '%' or '_' character?
Please help me!
Thanks!
Hi.
You have to escape the special characters in advance.
where Movie.PlotSummary like '%[%]%'
Movie.Plot
or
where Movie.PltSummary like '%!%%' escape '!'
will probably do.