HEX
Server: Apache
System: Linux s198.coreserver.jp 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC 2025 x86_64
User: nagasaki (10062)
PHP: 7.1.33
Disabled: NONE
Upload Files
File: //usr/local/rvm/gems/default/doc/activerecord-6.1.4.1/ri/ActiveRecord/Relation/update_counters-i.ri
U:RDoc::AnyMethod[iI"update_counters:ETI"+ActiveRecord::Relation#update_counters;TF:publico:RDoc::Markup::Document:@parts[
o:RDoc::Markup::Paragraph;	[I"AUpdates the counters of the records in the current relation.;To:RDoc::Markup::BlankLineS:RDoc::Markup::Heading:
leveli	:	textI"Parameters;T@o:RDoc::Markup::List:
@type:BULLET:@items[o:RDoc::Markup::ListItem:@label0;	[o;
;	[I"p+counter+ - A Hash containing the names of the fields to update as keys and the amount to update as values.;To;;0;	[o;
;	[I"H<tt>:touch</tt> option - Touch the timestamp columns when updating.;To;;0;	[o;
;	[I"YIf attributes names are passed, they are updated along with update_at/on attributes.;T@S;;
i	;I"
Examples;T@o:RDoc::Markup::Verbatim;	[I"E# For Posts by a given author increment the comment_count by 1.
;TI"GPost.where(author_id: author.id).update_counters(comment_count: 1);T:@format0:
@fileI""lib/active_record/relation.rb;T:0@omit_headings_from_table_of_contents_below000[I"(counters);T@(FI"
Relation;TcRDoc::NormalClass00