Updated mysql batch file and other php files to use stored procedures. Other bugs in room changing has been fixed.