Add a repr method to db objects and a console tool