/** * Снимает пометку "по-умолчанию" со всех автомобилей * * @return \MSergeev\Core\Lib\DBResult */ public static function uncheckDefaultAllCars() { $helper = new SqlHelper(); $query = new Query('update'); $sql = "UPDATE\n\t" . $helper->wrapQuotes(MyCarTable::getTableName()) . "\nSET\n\t" . $helper->wrapQuotes('DEFAULT') . " = 'N'\nWHERE\n\t" . $helper->wrapQuotes('DEFAULT') . " = 'Y';"; $query->setQueryBuildParts($sql); $res = $query->exec(); return $res; }