Do you mean if (!$this->sql_query($sql)) ?