Minor corrections to methods in database.java