change sql3 to mysql2