Beginning workings of the functionality. Ended up rewriting more than just database