viion Posted February 16, 2009 Share Posted February 16, 2009 I need to filter out specific terms in the SQL Query, so it doesnt pull information if they = a specific value. Link to comment https://forums.phpfreaks.com/topic/145440-solved-avoid-specific-terms-in-sql-query/ Share on other sites More sharing options...
Mchl Posted February 16, 2009 Share Posted February 16, 2009 WHERE field NOT IN (term1,term2,term3,...) Link to comment https://forums.phpfreaks.com/topic/145440-solved-avoid-specific-terms-in-sql-query/#findComment-763501 Share on other sites More sharing options...
viion Posted February 16, 2009 Author Share Posted February 16, 2009 Worked like a charm. I think because I didnt use () I didn't need the IN (i got errors when i did), so my final was just: AND NOT is_paid='0' Thank you Link to comment https://forums.phpfreaks.com/topic/145440-solved-avoid-specific-terms-in-sql-query/#findComment-763511 Share on other sites More sharing options...
Mchl Posted February 16, 2009 Share Posted February 16, 2009 If it's just one value you want to filter, you may also use WHERE is_paid != '0' Link to comment https://forums.phpfreaks.com/topic/145440-solved-avoid-specific-terms-in-sql-query/#findComment-763513 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.