Comment 1 for bug 619667

Revision history for this message
Timo Westkämper (timo-westkamper) wrote : Re: SQL: Add support for special options in insert clause

Fixed in SVN trunk. The DML clause implementations of the SQL module support now START, START_OVERRIDE and END flags. Use them like this :

    @Test
    public void insert_with_special_options(){
        SQLInsertClause clause = insert(survey)
            .columns(survey.id, survey.name)
            .values(3, "Hello");

        clause.addFlag(Position.START_OVERRIDE, "INSERT IGNORE INTO ");

        assertEquals("INSERT IGNORE INTO SURVEY(ID, NAME) values (?, ?)", clause.toString());
        clause.execute();
    }