It is time to add some data to our table in the created database. We will insert a row, which is sometimes called a record. A record in the
People table consists of values in three columns: PersonId, FirstName, and LastName. These values are going to be based on property values of an instance of the
Person class, which is mapped to the
People table. This is an important concept to remember. When we create entity classes, their purpose is to map to tables. There are some exceptions to this rule, which we will see in later chapters. This table is represented by a collection-based property in our
This property's type is
DbSet of Person and its name is
People. Conceptually, you can think of adding ...