public function refSQL() { /** @type SQL_Model $q */ $q = $this->ref('model'); $q->addCondition($q->id_field, $this); return $q; }