【发布时间】:2019-03-15 12:06:52
【问题描述】:
我正在使用 Entity Framework 6,我正在尝试选择具有最大版本号的实体,其中 Id = myId。
所以考虑一下。
Public class MyObject
{
int Id {get;set;}
int Version {get;set;}
string stuff {get;set;}
}
我看过这个答案 C# Entity Framework select max after where filter of not nullable field
但它只给了我整数值作为结果 - 我想要实体本身的整个记录,如果你愿意的话,整个 Enchilada..
【问题讨论】:
标签: c# select entity-framework-6 max where