added db methods; more test