added date in query, normalized predicates