Update DuckDb

This commit is contained in:
sunkaixuan 2025-04-20 18:34:28 +08:00
parent 4876fc8f9d
commit 281cd86f2f
5 changed files with 16 additions and 16 deletions

View File

@ -42,7 +42,6 @@ namespace OrmTest
new StudentWithSnowflake() { Name = "name",Id=SnowFlakeSingle.Instance.NextId() },
new StudentWithSnowflake() { Name = "name",Id=SnowFlakeSingle.Instance.NextId()}
};
db.Fastest<StudentWithSnowflake>().BulkCopy(listLong);
}
// 实体类带自增主键Entity class: With auto-increment primary key

View File

@ -55,9 +55,6 @@ namespace OrmTest
.IgnoreColumns(ignoreAllNullColumns: true, ignoreAllDefaultValue:true)
.ExecuteCommand();
// 使用最快的方式批量更新实体对象列表Bulk update a list of entity objects using the fastest method
var result8 = db.Fastest<StudentWithSnowflake>().BulkUpdate(updateObjs);
/***************************表达式更新 (Expression Update)***************************/
// 使用表达式更新实体对象的指定列Update specific columns of the entity object using expressions

View File

@ -4,7 +4,19 @@ _1_CodeFirst.Init();
_2_DbFirst.Init();
_3_EasyQuery.Init();
_4_JoinQuery.Init();
_4_Subquery.Init();
_5_PageQuery.Init();
_6_NavQuery.Init();
_7_GroupQuery.Init();
_8_Insert.Init();
_9_Update.Init();
_a1_Delete.Init();
_a2_Sql.Init();
_a3_Merge.Init();
//_a4_SplitTable.Init();
_a5_GridSave.Init();
_a6_SqlPage.Init();
_a7_JsonType.Init();
_a8_SelectReturnType.Init();
Console.WriteLine("DEMO执行完成");
Console.Read();

View File

@ -29,14 +29,6 @@ namespace OrmTest
// 中文备注带异常处理的分页插入或更新操作每页1000条记录
// English Comment: Perform insert or update operation with exception handling and paging, 1000 records per page
db.Storageable(list).PageSize(1000, exrows => { }).ExecuteCommand();
// 中文备注使用Fastest方式批量合并数据用于大数据处理
// English Comment: Merge data using Fastest method (for big data processing)
db.Fastest<Order>().BulkMerge(list);
// 中文备注分页使用Fastest方式批量合并数据每页100000条记录用于大数据处理
// English Comment: Merge data using Fastest method with paging, 100000 records per page (for big data processing)
db.Fastest<Order>().PageSize(100000).BulkMerge(list);
}
[SqlSugar.SugarTable("Order_a3")]

View File

@ -40,7 +40,7 @@ namespace OrmTest
var listDtoAutoMap = db.Queryable<Student>()
.Select(it => new StudentDto
{
AppendColumn = 100 // 手动指定一列在自动映射 (Manually specify a column in automatic mapping)
AppendColumn =Convert.ToInt32( 100) // 手动指定一列在自动映射 (Manually specify a column in automatic mapping)
},
true) // true 表示开启自动映射 (true indicates enabling automatic mapping)
.ToList();