diff --git a/Src/Asp.NetCore2/SqlSugar/Abstract/InsertableProvider/InsertableProvider.cs b/Src/Asp.NetCore2/SqlSugar/Abstract/InsertableProvider/InsertableProvider.cs index 9e6ffbef8..811f2a9f3 100644 --- a/Src/Asp.NetCore2/SqlSugar/Abstract/InsertableProvider/InsertableProvider.cs +++ b/Src/Asp.NetCore2/SqlSugar/Abstract/InsertableProvider/InsertableProvider.cs @@ -312,7 +312,10 @@ namespace SqlSugar if (snowColumn != null) { var id =await this.ExecuteReturnSnowflakeIdAsync(); - snowColumn.PropertyInfo.SetValue(result, id); + if (Convert.ToInt64(snowColumn.PropertyInfo.GetValue(result)) == 0) + { + snowColumn.PropertyInfo.SetValue(result, id); + } return true; } else