I have the following query which searched an episode guide database for user inputted data:
$query = "SELECT *
FROM epguide
WHERE EpisodeTitle LIKE '%$trimmed%'
OR Synopsis LIKE '%$trimmed%'
OR Notes LIKE '%$trimmed%'
ORDER BY o";
This works OK, but when I add 'Series = '$ser' AND' it stops:
$query = "SELECT *
FROM epguide
WHERE Series = '$ser'
AND EpisodeTitle LIKE '%$trimmed%'
OR Synopsis LIKE '%$trimmed%'
OR Notes LIKE '%$trimmed%'
ORDER BY o";
It looks like it should work. What can I do to fix it?