bug fix: db structure