O'Reilly logo

Code-First Development with Entity Framework by Sergey Barskiy

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 2. Your First Entity Framework Application

In this chapter, we will work through the creation of a brand new project that uses Entity Framework. We will create classes that map to tables in the target database. We will then insert a row into that table using the Entity Framework API. We will also query this using LINQ. Next, we will update and delete our test data. Finally, we will take a look at how to handle schema changes.

In this chapter, we will cover the following topics:

  • Creating a new project using Entity Framework
  • Adding the necessary references to be able to write Entity Framework code
  • Creating a new database based on written classes
  • Saving a new record
  • Querying the saved data
  • Deleting and updating the data in the database
  • An introduction ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required