added initial db logic in main.java, have not compiled yet