instance method
combine_multi_statements
Ruby on Rails 5.2.8.1
Since v5.2.8.1 Last seen in v5.2.8.1 PrivateSignature
combine_multi_statements(total_sql)
No documentation comment.
Parameters
-
total_sqlreq
Source
# File activerecord/lib/active_record/connection_adapters/abstract_mysql_adapter.rb, line 536
def combine_multi_statements(total_sql)
total_sql.each_with_object([]) do |sql, total_sql_chunks|
previous_packet = total_sql_chunks.last
sql << ";\n"
if max_allowed_packet_reached?(sql, previous_packet) || total_sql_chunks.empty?
total_sql_chunks << sql
else
previous_packet << sql
end
end
end
Defined in activerecord/lib/active_record/connection_adapters/abstract_mysql_adapter.rb line 536
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::ConnectionAdapters::AbstractMysqlAdapter