handle newdatabase