adding Database and Task functions