Skip to content

UpsertOptions

struct

Defined in src/ralph/bulk_operations.cr:30

Options for upsert conflict resolution

Constructors

.new(conflict_columns : Array(String) = [] of String, update_columns : Array(String) = [] of String, do_nothing : Bool = false)

View source


Instance Methods

#conflict_columns

View source

Column(s) to check for conflicts


#do_nothing

View source

Whether to update nothing on conflict (INSERT IGNORE behavior)


#update_columns

View source

Columns to update on conflict (if empty, updates all non-conflict columns)