adapt init sql database.