Im trying to search a database giving the user the ability to filter based on 3 different criteria
- a text field
- list menu criteria pulled from db
- another list menu criteria pulled from db...
my problem is the search works in some cases but in others just returns ALL the records...
heres the sql select code Im using:
- a text field
- list menu criteria pulled from db
- another list menu criteria pulled from db...
my problem is the search works in some cases but in others just returns ALL the records...
heres the sql select code Im using:
Code:
SELECT *
FROM tbl_events
WHERE EventTitle Like '%var1%' Or EventDetail Like '%var1%' And City = 'var2' And EventCategory Like '%var3%'