public class CSVImport extends Object
Modifier and Type | Field and Description |
---|---|
protected boolean |
cleartable |
protected String[] |
columns |
protected Connection |
conn |
protected boolean |
ignorecolumns |
protected int |
ignorelines |
protected char |
quoteCharacter |
protected char |
separator |
protected boolean |
stripquotes |
protected String |
table |
Modifier and Type | Method and Description |
---|---|
void |
importCSV(InputStream csvfile) |
static void |
main(String[] argv) |
void |
setClearTable(boolean cleartable) |
void |
setColumns(String[] columns) |
void |
setIgnoreColumns(boolean ignorecolumns) |
void |
setIgnoreLines(int ignorelines) |
void |
setSeparator(char separator) |
void |
setStripQuotes(boolean stripquotes) |
void |
setTable(String table) |
protected static void |
usage() |
protected final Connection conn
protected String table
protected String[] columns
protected char quoteCharacter
protected char separator
protected boolean cleartable
protected boolean stripquotes
protected boolean ignorecolumns
protected int ignorelines
public void setTable(String table)
public void setColumns(String[] columns)
public void setSeparator(char separator)
public void setClearTable(boolean cleartable)
public void setStripQuotes(boolean stripquotes)
public void setIgnoreColumns(boolean ignorecolumns)
public void setIgnoreLines(int ignorelines)
public void importCSV(InputStream csvfile) throws Exception
Exception
protected static void usage()