メソッド | invoke validation | invoke callback | raise exception | 補足 |
---|---|---|---|---|
update(attributes) | o | o | x | |
update!(attributes) | o | o | o | |
update_attribute(name, value) | x | o | x | boolean flag の update が主な目的? |
update_attributes(attributes) | o | o | x | update の alias |
update_attributes!(attributes) | o | o | o | update! の alias |
update_column(name, value) | x | x | x | updated_columns(name: value) と同じ |
update_columns(attributes) | x | x | x | 最速でレコード更新できる。updated_at が更新されない |
More than 5 years have passed since last update.
Register as a new user and use Qiita more conveniently
- You get articles that match your needs
- You can efficiently read back useful information
- You can use dark theme
List of users who liked
1818