postgrelize / MergeInsertAction
Interface: MergeInsertAction<T> ​
Defined in: src/model/merge-options.ts:35
WHEN NOT MATCHED action of merge.
Set insert or nothing.
Example ​
ts
const action: MergeInsertAction<Product> = { insert: { sku: col('source.sku'), price: 0 } };Type Parameters ​
T ​
T
Properties ​
insert? ​
readonlyoptionalinsert?:true|Partial<Record<keyofT&string,unknown>>
Defined in: src/model/merge-options.ts:39
Values to insert: true copies same-named source columns, or a map of values / expressions.
nothing? ​
readonlyoptionalnothing?:true
Defined in: src/model/merge-options.ts:41
Do nothing.
where? ​
readonlyoptionalwhere?:unknown
Defined in: src/model/merge-options.ts:37
Extra condition (WHEN NOT MATCHED AND ...); may reference only source columns.