updates to entity query