I have the following data in a SQL table called tb_CField
CampaignID FieldName
739 L_extra1
739 L_extra2
739 L_extra3
When I access the data via the Entity Framework (v4), the object context method
oc.tb_CField()
the EntitySet contains three entries as I would expect but they are all
739 L_extra1
ie just the first record / entity ??
Your entity either has no DB primary key or has a primary key in the DB which is not correctly mapped in your entity model. Fix that.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.