typeorm
Version:
Data-Mapper ORM for TypeScript, ES7, ES6, ES5. Supports MySQL, PostgreSQL, MariaDB, SQLite, MS SQL Server, Oracle, MongoDB databases.
21 lines (20 loc) • 705 B
TypeScript
import { InsertOrUpdateOptions } from "../query-builder/InsertOrUpdateOptions";
import { UpsertType } from "../driver/types/UpsertType";
/**
* Special options passed to Repository#upsert
*/
export interface UpsertOptions<Entity> extends InsertOrUpdateOptions {
conflictPaths: string[] | {
[ ]?: true;
};
/**
* If true, postgres will skip the update if no values would be changed (reduces writes)
*/
skipUpdateIfNoValuesChanged?: boolean;
/**
* Define the type of upsert to use (currently, CockroachDB only).
*
* If none provided, it will use the default for the database (first one in the list)
*/
upsertType?: UpsertType;
}