change db scheme and correct some error