/**
  * Filter the query by a related \Profile object
  *
  * @param \Profile|ObjectCollection $profile  the related object to use as filter
  * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @return ChildAccountQuery The current query, for fluid interface
  */
 public function filterByProfile($profile, $comparison = null)
 {
     if ($profile instanceof \Profile) {
         return $this->addUsingAlias(AccountTableMap::COL_ID, $profile->getId(), $comparison);
     } elseif ($profile instanceof ObjectCollection) {
         return $this->useProfileQuery()->filterByPrimaryKeys($profile->getPrimaryKeys())->endUse();
     } else {
         throw new PropelException('filterByProfile() only accepts arguments of type \\Profile or Collection');
     }
 }
 /**
  * Exclude object from result
  *
  * @param   ChildProfile $profile Object to remove from the list of results
  *
  * @return $this|ChildProfileQuery The current query, for fluid interface
  */
 public function prune($profile = null)
 {
     if ($profile) {
         $this->addUsingAlias(ProfileTableMap::COL_ID, $profile->getId(), Criteria::NOT_EQUAL);
     }
     return $this;
 }