Class: upsertMany

upsertMany(table, uuid, records, options) → {Operation}

new upsertMany(table, uuid, records, options) → {Operation}

Insert or update multiple records using ON CONFLICT UPDATE and excluded
Parameters:
Name Type Description
table string The target table
uuid string The uuid column to determine a matching/existing record
records function A function that takes state and returns an array of records
options object Optional options argument
Source:
Returns:
Type
Operation
Example
upsertMany(
 'users', 'email', records, { logValues: false }
)
upsertMany(
 'users', ['email', 'phone'], records, { logValues: false }
)