Remove hidden properties from the query statement