Tree To DataBase