Cleanup the influx query parsing