include expiration clause in query