use of org.jooq.InsertQuery in project collect by openforis.
the class MappingDSLContext method insertQuery.
@SuppressWarnings({ "rawtypes" })
public InsertQuery insertQuery(E object) {
Integer id = getId(object);
if (id == null) {
int nextId = nextId();
setId(object, nextId);
}
InsertQuery insert = insertQuery(getTable());
fromObject(object, insert);
return insert;
}
use of org.jooq.InsertQuery in project jOOQ by jOOQ.
the class DefaultDSLContext method executeInsert.
@Override
public int executeInsert(TableRecord<?> record) {
InsertQuery insert = insertQuery(record.getTable());
insert.setRecord(record);
return insert.execute();
}
Aggregations