gpt4 book ai didi

c# - EF 代码首先排除列

转载 作者:太空狗 更新时间:2023-10-29 22:33:21 25 4
gpt4 key购买 nike

<分区>

Possible Duplicate:
Exclude a field/property from the database with Entity Framework 4 & Code-First

我正在使用 EF 4 代码优先。

有什么方法可以排除在数据库中创建列吗?

例如,我想排除要创建的 Zip 列。

public string Address { get; set; }
[StringLength(40)]
public string City { get; set; }
[StringLength(30)]
public string State { get; set; }
[StringLength(10)]
public string Zip { get; set; }

谢谢。

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com