语言

UpdateDatabaseOperation(IList<DbQueryCommandTree>) 构造函数

定义

初始化 UpdateDatabaseOperation 类的新实例。

实体框架迁移 API 不设计为接受不受信任的源提供的输入(例如应用程序的最终用户)。 如果从此类源接受输入,则应在传递给这些 API 之前对其进行验证,以防止 SQL 注入攻击等。

public UpdateDatabaseOperation(System.Collections.Generic.IList<System.Data.Entity.Core.Common.CommandTrees.DbQueryCommandTree> historyQueryTrees);
new System.Data.Entity.Migrations.Model.UpdateDatabaseOperation : System.Collections.Generic.IList<System.Data.Entity.Core.Common.CommandTrees.DbQueryCommandTree> -> System.Data.Entity.Migrations.Model.UpdateDatabaseOperation
Public Sub New (historyQueryTrees As IList(Of DbQueryCommandTree))

参数

historyQueryTrees
IList<DbQueryCommandTree>

用于确定此迁移是否需要应用于数据库的查询。 这用于生成可在任何版本中针对数据库运行的幂等 SQL 脚本。

适用于