Skip to content

Batch for ActiveRecord #85

Description

@g8d3

Would it be possible to add a batch method for ActiveRecord:

Model.upsert do |u|
  # N times
  u.row attr1: val1
end

And detect created_at and updated_at, so you do not have to write:

now = Time.now
u.row attr1: val1, created_at: now, updated_at: now

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions