finished new dbhandling

now, the rest of the program must be adapted to the new dbhandling