Search in sources :

Example 1 with InsertValuesStep19

use of org.jooq.InsertValuesStep19 in project hmftools by hartwigmedical.

the class CanonicalTranscriptDAO method write.

void write(@NotNull List<CanonicalTranscript> transcripts) {
    Timestamp timestamp = new Timestamp(new Date().getTime());
    context.delete(CANONICALTRANSCRIPT).execute();
    for (List<CanonicalTranscript> split : Iterables.partition(transcripts, DB_BATCH_INSERT_SIZE)) {
        InsertValuesStep19 inserter = context.insertInto(CANONICALTRANSCRIPT, CANONICALTRANSCRIPT.GENE, CANONICALTRANSCRIPT.GENEID, CANONICALTRANSCRIPT.CHROMOSOMEBAND, CANONICALTRANSCRIPT.CHROMOSOME, CANONICALTRANSCRIPT.GENESTART, CANONICALTRANSCRIPT.GENEEND, CANONICALTRANSCRIPT.TRANSCRIPTID, CANONICALTRANSCRIPT.TRANSCRIPTVERSION, CANONICALTRANSCRIPT.TRANSCRIPTSTART, CANONICALTRANSCRIPT.TRANSCRIPTEND, CANONICALTRANSCRIPT.EXONS, CANONICALTRANSCRIPT.EXONSTART, CANONICALTRANSCRIPT.EXONEND, CANONICALTRANSCRIPT.EXONBASES, CANONICALTRANSCRIPT.CODINGSTART, CANONICALTRANSCRIPT.CODINGEND, CANONICALTRANSCRIPT.CODINGBASES, CANONICALTRANSCRIPT.STRAND, CANONICALTRANSCRIPT.MODIFIED);
        split.forEach(x -> addRecord(timestamp, inserter, x));
        inserter.execute();
    }
}
Also used : CanonicalTranscript(com.hartwig.hmftools.common.gene.CanonicalTranscript) Timestamp(java.sql.Timestamp) Date(java.util.Date) InsertValuesStep19(org.jooq.InsertValuesStep19)

Aggregations

CanonicalTranscript (com.hartwig.hmftools.common.gene.CanonicalTranscript)1 Timestamp (java.sql.Timestamp)1 Date (java.util.Date)1 InsertValuesStep19 (org.jooq.InsertValuesStep19)1