Working with Keys
暂无分享,去创建一个
Selecting the most suitable keys for your data sets the foundation for the rest of the data model. In earlier chapters, you have seen the role that keys play in uniquely identifying objects, the conventions that Entity Framework Core uses to select properties to use as keys, and how these conventions are overridden. In this chapter, I describe the advanced key features that Entity Framework Core provides. Like many of the features described in this part of the book, you are unlikely to need the advanced key features in every project that uses Entity Framework Core, but the ability to take control of how keys are used can be important for those unusual occasions when the standard features can’t deliver the functionality your application required.