mod. logging. move query defs out of methods (to be moved out of module).
add/mod. delete_usertags and delete_usertags_meta methods.  pep8.