jaymc Posted February 6, 2007 Share Posted February 6, 2007 Would it be possible to turn this into one query $queryupdate = "UPDATE `blte_online` SET `rtime` = '$timestamp' WHERE `usr_name` = '$User_Session' LIMIT 1"; $query='SELECT * FROM '.$prefix."_online WHERE ($timestamp-rtime)<20 ORDER BY `group` DESC, `gen` ASC, `usr_name` ASC"; $result=mysql_query($query); In otherwords, can you perform UPDATE and SELECT and have it executed in one query.. Quote Link to comment Share on other sites More sharing options...
artacus Posted February 6, 2007 Share Posted February 6, 2007 No, but you could technically do the update in a subquery but I really don't see the point. It wouldn't speed things up any. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.