initial version of txdb, minor fixes