Code example for Statement

Methods: execute

0
            + "VALUES (3011, 9891.88, 10/06/1990, 2006, 1001)"; 
 
    public static void fillParentTable(Connection conn) throws SQLException {
        Statement statement = conn.createStatement();
        statement
                .execute("INSERT INTO " + PARENT_TABLE + " VALUES(1, 'test1')");
        statement.execute("INSERT INTO " + PARENT_TABLE + " VALUES(2,'test2')");
        statement
                .execute("INSERT INTO " + PARENT_TABLE + " VALUES(3, 'test3')");
    } 
 
    public static void fillFKStrictTable(Connection conn) throws SQLException {
        Statement statement = conn.createStatement();
        statement.execute("INSERT INTO " + FKSTRICT_TABLE
                + " VALUES(1, 1, '1')"); 
        statement.execute("INSERT INTO " + FKSTRICT_TABLE
                + " VALUES(2, 2, '2')"); 
        statement.execute("INSERT INTO " + FKSTRICT_TABLE
                + " VALUES(3, 1, '3')"); 
    } 
Contextual code suggestions in your IDE  Get Codota for Java