fix degree clean query string