get db in repo