Bug fixes for pushing down predicates