move functions from testclass to dbrec