I am trying to update rows with a particular value using Jackcess in Java. I am using the below code and there is no changes done to the rows.
What I am missing here? I am feeling lost as there is no documentation for these methods.
Database db = DatabaseBuilder.open(new File("Db.mdb"));
Table table = db.getTable("Table1");
Cursor cursor = CursorBuilder.createCursor(table);
Map<String, Object> map = new HashMap<String, Object>();
map.put("Active", true); // Value to be updated
for (Row row : cursor.newIterable().addMatchPattern("testnum", testNum)) {
cursor.updateCurrentRow(table.asUpdateRow(map));
}
db.flush();
db.close();