public function getSqlAppointmentsWhere()
    {
        $where = $this->getSqlEpisodeWhere();

        if (($where == parent::NO_MATCH_SQL) || ($where == parent::MATCH_ALL_SQL)) {
            return $where;
        }

        return sprintf(
                "gap_id_episode IN (SELECT gec_episode_of_care_id FROM gems__episodes_of_care WHERE %s)",
                $where
                );
    }
public function getSqlAppointmentsWhere()
    {
        $where = $this->getSqlEpisodeWhere();

        if (($where == parent::NO_MATCH_SQL) || ($where == parent::MATCH_ALL_SQL)) {
            return $where;
        }

        return sprintf(
                "gap_id_episode IN (SELECT gec_episode_of_care_id FROM gems__episodes_of_care WHERE %s)",
                $where
                );
    }
public function getSqlAppointmentsWhere ( ) { $ where = $ this -> getSqlEpisodeWhere ( ) ; if ( ( $ where == parent :: NO_MATCH_SQL ) || ( $ where == parent :: MATCH_ALL_SQL ) ) { return $ where ; } return sprintf ( "gap_id_episode IN (SELECT gec_episode_of_care_id FROM gems__episodes_of_care WHERE %s)" , $ where ) ; }
Generate a where statement to filter an appointment model

@return string
Generate a where statement to filter an appointment model