sbourdon Posted May 23, 2006 Share Posted May 23, 2006 Hello,I would like to create a php script that would execute a SQL query that would do the following:Inside the topics_watch table, set the notify_status value to 0 for all users EXCEPT user_id 2.What should the SQL query be?Thanks for your help! [img src=\"style_emoticons/[#EMO_DIR#]/wink.gif\" style=\"vertical-align:middle\" emoid=\":wink:\" border=\"0\" alt=\"wink.gif\" /] Link to comment https://forums.phpfreaks.com/topic/10268-sql-query-a-little-help-please/ Share on other sites More sharing options...
micah1701 Posted May 23, 2006 Share Posted May 23, 2006 UPDATE topics_watch SET notify_staus = 0 WHERE user_id NOT LIKE 2 Link to comment https://forums.phpfreaks.com/topic/10268-sql-query-a-little-help-please/#findComment-38259 Share on other sites More sharing options...
sbourdon Posted May 23, 2006 Author Share Posted May 23, 2006 [!--quoteo(post=376352:date=May 23 2006, 09:30 AM:name=micah1701)--][div class=\'quotetop\']QUOTE(micah1701 @ May 23 2006, 09:30 AM) [snapback]376352[/snapback][/div][div class=\'quotemain\'][!--quotec--]UPDATE topics_watch SET notify_staus = 0 WHERE user_id NOT LIKE 2[/quote]Perfect; thanks a lot! Link to comment https://forums.phpfreaks.com/topic/10268-sql-query-a-little-help-please/#findComment-38301 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.