Updated SQL and MySQL scripts