Implemented DB mechanics