public long copyIn(final String sql, InputStream from) throws SQLException, IOException {
    return copyIn(sql, from, DEFAULT_BUFFER_SIZE);
  }
public long copyIn ( final String sql , InputStream from ) throws SQLException , IOException { return copyIn ( sql , from , DEFAULT_BUFFER_SIZE ) ; }
Use COPY FROM STDIN for very fast copying from an InputStream into a database table.

@param sql COPY FROM STDIN statement
@param from a CSV file or such
@return number of rows updated for server 8.2 or newer; -1 for older
@throws SQLException on database usage issues
@throws IOException upon input stream or database connection failure