mysql - SQL not returning expected rows -
my sql select statement not returning correct rows. have table named activities , statement should output rows column 'approved' = yes , of cells have text 'test'. statement still outputting of rows approved = no, not of them.
this sql statement:
select * activities approved = 'yes' , title '%test%' or subject '%test%' or industry '%test%' or description '%test%' order date_added desc
move or conditions within ()
as
select * activities approved = 'yes' , ( title '%test%' or subject '%test%' or industry '%test%' or description '%test%' ) order date_added desc
so filter as
- if approved = 'yes'
- and title or subject ....
Comments
Post a Comment