Added remaining DB functionality