the query is just as easy:
[sql]UPDATE user SET usergroupid=X WHERE userid=yyy AND usergroupid=y[/sql]
you just have to replce the variables..
the second paragraph: you need to add another field to the user-table via phpmyadmin
then when runing the query above, you should add a part: ,userupgradedate=".time()."
to automatically move him back to his old usergroup you can add this line at the end of your global.php:
PHP Code:
if($bbuserinfo[usergroupid]==x and $bbuserinfo[userupgradedate]<time()-3600*24*30) {
$DB_site->query("UPDATE user SET usergroupid=y WHERE userid=$bbuserinfo[userid]");
}