implement tested and functional mysql interfacing *FINALLY*