FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Combining Update Queries





coreymanshack
I have these two update queries that I want to combine into one, how do I do that?

$sql_query = mysql_query("UPDATE users SET atkturns = '$whole' WHERE ID = '$userid'");
$sql_query = mysql_query("UPDATE users SET nxtturn = '$updatetime' WHERE ID = '$userid'");
mathiaus
Put all the sets together
Code:
 $sql_query = mysql_query("UPDATE users SET atkturns = '$whole', nxtturn = '$updatetime' WHERE ID = '$userid'");
coreymanshack
mathiaus wrote:
Put all the sets together
Code:
 $sql_query = mysql_query("UPDATE users SET atkturns = '$whole', nxtturn = '$updatetime' WHERE ID = '$userid'");


thank you muchly this was exactly what i was looking for.
Related topics
Bogus Microsoft Security Update Circulates
How To : Improve Your PHP Programming
My Laptop prblm
Think only Windows Update will keep you safe?
Frankfurt Motor Show, 2005
Firefox 1.0.7 Released
MSCONFIG, update from MicroSoft
Google PR Update
Google update PageRank's
phpBBFM update
[UPDATE] zip support
MySQL SUBselect queries and Nested queries
Fake Windows Update
AJAX + PHP, UPDATE mysql table nto working.
Reply to topic    Frihost Forum Index -> Scripting -> Php and MySQL

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.