Begin implement db logic.