import csv to Mdb with java

31 views Asked by At

I have a mdb file (inventory.mdb) with different empty tables (store1, store2, ...) and I have hunderd csv data. I should read and save the csv files into LinkedList and write them in different tables in mdb file.

I import and save the csv with this method: (storedata is a linked list)

private void loadTxtForStores(String path)
{
    try (BufferedReader br = new BufferedReader(new FileReader(path));)
    {
        
        String line = br.readLine();
        while (line != null) {
            storedata.add(line.split(";"));
            line = br.readLine();   
        }
        
    }
    
    catch (IOException ioe) 
    {
        ioe.printStackTrace();
    }
}

But I have no idea how can I write them into the mdb. I think this is possible with a proprate library.

mdb file

0

There are 0 answers