moved most over to MySQL, still some bugs