Changed db structure