yii\db\ActiveRecordInterface::updateAll PHP 메소드

updateAll() 공개 정적인 메소드

For example, to change the status to be 1 for all customers whose status is 2: php Customer::updateAll(['status' => 1], ['status' => '2']);
public static updateAll ( array $attributes, array $condition = null ) : integer
$attributes array attribute values (name-value pairs) to be saved for the record. Unlike [[update()]] these are not going to be validated.
$condition array the condition that matches the records that should get updated. Please refer to [[QueryInterface::where()]] on how to specify this parameter. An empty condition will match all records.
리턴 integer the number of rows updated
    public static function updateAll($attributes, $condition = null);