protected void create(String fullId,String type,String localId,Map<String,Object> obj,Connection connection,PreparedStatement createStatement,boolean batchCreate) throws SQLException, IOException {
  logger.debug("Create with fullid {}",fullId);
  String rev="0";
  obj.put("_id",localId);
  obj.put("_rev",rev);
  JsonValue objVal=new JsonValue(obj);
  logger.debug("Preparing statement {} with {}, {}, {}",createStatement,type,localId,rev);
  populatePrepStatementColumns(createStatement,objVal,tokenReplacementPropPointers);
  if (!batchCreate) {
    logger.debug("Executing: {}",createStatement);
    int val=createStatement.executeUpdate();
    logger.debug("Created object for id {} with rev {}",fullId,rev);
  }
 else {
    createStatement.addBatch();
    logger.debug("Added create for object id {} with rev {} to batch",fullId,rev);
  }
}

protected void create ( String fullId , String type , String localId , Map < String , Object > obj , Connection connection , PreparedStatement createStatement , boolean batchCreate ) throws SQLException , IOException { logger . debug ( "Create with fullid {}" , fullId ) ; String rev = "0" ; obj . put ( "_id" , localId ) ; obj . put ( "_rev" , rev ) ; JsonValue objVal = new JsonValue ( obj ) ; logger . debug ( "Preparing statement {} with {}, {}, {}" , createStatement , type , localId , rev ) ; populatePrepStatementColumns ( createStatement , objVal , tokenReplacementPropPointers ) ; if ( ! batchCreate ) { logger . debug ( "Executing: {}" , createStatement ) ; int val = createStatement . executeUpdate ( ) ; logger . debug ( "Created object for id {} with rev {}" , fullId , rev ) ; } else { createStatement . addBatch ( ) ; logger . debug ( "Added create for object id {} with rev {} to batch" , fullId , rev ) ; } }
adds the option to batch more than one create statement
