changed the setup functions to use retriveAsInt from dbhandler