fix error when StorageableByObject(null) or StorageableByObject(new List<xx>())

This commit is contained in:
SW
2024-06-11 18:49:22 +08:00
parent cbb7a670c6
commit 21198be833
2 changed files with 8 additions and 4 deletions

View File

@@ -52,7 +52,10 @@ namespace OrmTest
// 忽略为NULL和默认值的列进行更新Ignore columns with NULL and default values during update
var result7 = db.Updateable(updateObj)
.IgnoreColumns(ignoreAllNullColumns: true, ignoreAllDefaultValue:true)
.IgnoreColumns(ignoreAllNullColumns: true, ignoreAllDefaultValue: true)
.ExecuteCommand();
var result7a = db.StorageableByObject(new List<StudentWithSnowflake>()).ToStorage().AsUpdateable
.IgnoreColumns(new[] { "" })
.ExecuteCommand();
// 使用最快的方式批量更新实体对象列表Bulk update a list of entity objects using the fastest method