I am writing a generic function to insert data into SQLtables and I am wondering how to improve my current implementation.
My current function looks like:
public void insertIntoDatabase(String table, ArrayList<String> insertRow) {
..
}
table - Name of the SQL table insertRow - ArrayList of values to insert
Some tables also contain other attributes than VARCHARS so I am considering ArrayList<xtable> insertRow
But is it necessary to write individual java classes for each database table ?
Thanks for your help! M