我正在尝试将表格列的类型从int
更改为long
。
AlterColumn("dbo.Files", "Size", c => c.Long(nullable: false));
它在迁移时抛出错误:
The object 'DF__Files__Size__1FCDBCEB' is dependent on column 'Size'.
ALTER TABLE ALTER COLUMN Size failed because one or more objects access this column.
如何删除实体框架中的约束...进行迁移,然后将其重新放入?