I am working on an asp.net mvc-4 web application and i am using Entity Framework 5.0 . now i have mapped my sql server 2008 tables using entity framework with database first approach. but i got this strange issue after completing the mapping, now inside my database i have a table named ""People as follow:-
but on the generated edmx file the table was renamed as "Person" , here is how the entity looks like inside my edmx file :-
here is the generated model class:-
using System;
using System.Collections.Generic;
public partial class Person
{
public long CIID { get; set; }
public string ATTRIBUTE_1202 { get; set; }
public virtual BaseElement BaseElement { get; set; }
public virtual Requester Requester { get; set; }
public virtual Technician Technician { get; set; }
}
}
so can anyone adivce why the "People" table is presented as an Entity named "Person" inside the .edmx file ?
I think, you checked option "Pluralize or aingularize generated object names".
So People
means many, Person
means single.
Usually, it just adds or removes s
and es
in the end, but in some cases it does more complex replacements.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With