rudimentary working database functionality