Fixed more bug in database update while changing path