move as much as possible into table_t all of the sql interactions. exception being the threaded stopping stuff. which will be next on the block. also removed count from taginfo as it wasnt really used and prevented moving the logic into table_t
merge mla branch and kk branch