fix SQL query when update role