insertOrIgnore method
Statement
insertOrIgnore(
- QualifiedTablename table,
- List<
String> columns, - List<
Object?> values
override
Insert a row into a table, ignoring it if it already exists.
Implementation
@override
Statement insertOrIgnore(
QualifiedTablename table,
List<String> columns,
List<Object?> values,
) {
return Statement(
'''
INSERT OR IGNORE INTO $table (${columns.join(', ')})
VALUES (${columns.map((_) => '?').join(', ')});
''',
values,
);
}