Code refactoring

Deleted useless DB data structure and combined into MySQL class