ChrisDarl Posted February 10, 2007 Share Posted February 10, 2007 Hi guys, I'm trying to update multiple rows in my database.... this is what i've tried mysql_query("update [fields and values to update; update [fields and values to update]"); but it comes up with errors, am i just going to have to split them up to seperate mysql_query()'s or is there a work around? Idealy i would like to do it in the one query because i want to return the number of rows effected. Thanks in advance Chris Link to comment https://forums.phpfreaks.com/topic/37949-multiple-updates-in-one-mysql_query-how-can-it-be-done/ Share on other sites More sharing options...
Jessica Posted February 10, 2007 Share Posted February 10, 2007 I think you'll have to do several queries - but then you can just add up the numbers to get the total. Link to comment https://forums.phpfreaks.com/topic/37949-multiple-updates-in-one-mysql_query-how-can-it-be-done/#findComment-181610 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.