additional validations for query.