improvements to db