Table of Contents
Preface
Chapter 1: Introducing the ADO.NET Entity Framework
Chapter 2: Getting Started
Chapter 3: Entities, Relationships, and the Entity Data Model
Chapter 4: Working with Stored Procedures in the Entity Data Model
Chapter 5: Working with Entity Client and Entity SQL
Chapter 6: Working with LINQ to Entities
Chapter 7: Working with the Object Services Layer
Chapter 8: Introducing ADO.NET Data Services
Index
- Chapter 1: Introducing the ADO.NET Entity Framework
- What You should Know
- Looking Back
- What is ADO.NET Entity Framework?
- Is It Just Another ORM?
- The ADO.NET Entity Framework Architectural Components
- The Entity Data Model (EDM)
- How is the Entity Data Model Represented?
- The Object Model (O-Space)
- LINQ to Entities
- Entity Client
- Entity SQL
- Avoiding Complex Joins
- The Object Services Layer
- ADO.NET Entity Framework—Features and Benefits at a Glance
- Installing the Prerequisites
- Installing the ADO.NET Entity Framework and Its Tools
- Downloading the Software
- Installing the Software
- Installing the ADO.NET Entity Framework and Its Tools
- Designing the Payroll Database
- Summary
- Glossary
- Chapter 2: Getting Started
- Creating an Entity Data Model
- Creating the Payroll Entity Data Model Using the ADO.NET Entity Data Model Designer
- Creating the Payroll Data Model Using the EdmGen Tool
- The ADO.NET Entity Data Source Control
- Implementing Our First Application Using the Entity Framework
- Summary
- Creating an Entity Data Model
- Chapter 3: Entities, Relationships, and the Entity Data Model
- Entities, Entity Types, and Relationships in the ADO.NET Entity Data Model (EDM)
- What is an Entity?
- Defining Entity Sets in the Entity Data Model
- Extending the Existing Entity Types to Create Derived Entity Types
- Association Sets, Associations, Containment, and Multiplicity
- What are Entity Containers?
- Exploring the Payroll Entity Data Model
- The Mapping Details Window
- The Entity Model Browser
- The Entity Data Model Layers
- The CSDL Schema
- The SSDL Schema
- The MSL Schema
- Summary
- Entities, Entity Types, and Relationships in the ADO.NET Entity Data Model (EDM)
- Chapter 4: Working with Stored Procedures in the Entity Data Model
- Mapping Stored Procedures to Functions in the EDM
- Mapping Create, Update, and Delete Functions to Entities in the EDM
- Mapping the Association Sets Consistently
- Mapping Stored Procedures with No Entity Set
- Mapping Stored Procedures to Functions in the EDM
- Using Stored Procedures
- Mapping Stored Procedures that Return Custom Entity Types
- Summary
- Chapter 5: Working with Entity Client and Entity SQL
- An Overview of the Entity SQL Language
- From Transact SQL (T-SQL) to Entity SQL (E-SQL)
- Why Entity SQL When I Already have LINQ to Entities?
- Features of Entity SQL
- Operators in Entity SQL
- Arithmetic Operators
- Comparison Operators
- Logical Operators
- Reference Operators
- Type Operators
- Set Operators
- Operator Precedence
- Expressions in Entity SQL
- Query Expressions in Entity SQL
- Identifiers, Variables, Parameters, and Types in Entity SQL
- Row
- Collection
- Reference
- Canonical Functions in Entity SQL
- Mathematical Functions
- Aggregate Functions
- String Functions
- Bitwise Functions
- Date and Time Functions
- Data Paging Using Entity SQL
- Working with the ADO.NET Entity Client
- Let's Get into Action
- Building the Connection String
- Creating an Entity Connection
- Opening the Connection
- Executing Queries Using the Entity Command
- Closing the Connection
- Let's Get into Action
- Other Operations with Entity SQL
- Inserting a Record Using Entity SQL
- Inserting a Record with a Foreign Key Constraint
- Retrieving Native SQL from EntityCommand
- Transaction Management in Entity SQL
- Summary
- An Overview of the Entity SQL Language
- Chapter 6: Working with LINQ to Entities
- Introducing LINQ
- Why LINQ?
- Understanding the LINQ Architecture
- LINQ to XML
- LINQ to SQL
- LINQ to Objects
- LINQ to Entities
- Querying Data Using LINQ to Entities
- LINQ to Entities and Entity Framework
- Differences between LINQ to Entities and LINQ to SQL
- Operators in LINQ
- Aggregation
- Projections
- Ordering
- Quantifiers
- Restriction
- Conversion
- Element
- Set
- Introducing LINQ
- Querying Data Using LINQ
- Expressions in LINQ to Entities
- Constant Expressions
- Comparison Expressions
- Initializing Expressions
- Null Comparisons
- Navigation Properties
- Immediate and Deferred Query Execution
- Improving Performance with Compiled Queries
- Expressions in LINQ to Entities
- Summary
- Chapter 7: Working with the Object Services Layer
- What are Object Services?
- Features at a Glance
- A Quick Look at the ObjectContext Class in our Payroll EDM
- Querying Data as in-Memory Objects
- Adding, Modifying, and Deleting Objects
- Attaching and Detaching Objects to and from the Object Context
- Serializing and De-Serializing Entity Instances
- Change Tracking and Identity Resolution Using ObjectContext
- Implementing a Sample Application
- Creating the Form
- Implementing a Custom DataContext
- How is This Accomplished?
- Inheritance in the Entity Framework
- Table per Hierarchy
- Table per Type
- What are Object Services?
- Implementing Complex Types in the EDM
- Summary
- Chapter 8: Introducing ADO.NET Data Services
- Introducing ADO.NET Data Services
- How Do ADO.NET Data Services and Web Services Differ?
- What is Representational State Transfer (REST)?
- Why Use ADO.NET Data Services?
- Features at a Glance
- Prerequisites
- Exposing Data as a Service Using ADO.NET Data Services
- Creating an ADO.NET Data Service
- Using a Relational Database as the Data Source
- Using Data Sources Other Than a Relational Database
- Understanding the System.Services.Data Namespace
- Restricting Access to Resources
- Working with the ADO.NET Data Service Client Library
- Generating the Client-Side Entity Classes
- Inserting a Record
- Updating a Record
- Deleting a Record
- Consuming an ADO.NET Data Service Using LINQ
- Exposing a Stored Procedure as a URI
- Handling Exceptions in ADO.NET Data Services
- Batching ADO.NET Data Services Requests to Improve Performance
- Debugging Your Data Service
- References
- Summary
- Introducing ADO.NET Data Services



