Search icon
Subscription
0
Cart icon
Close icon
You have no products in your basket yet
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Entity Framework Core Cookbook - Second Edition

You're reading from  Entity Framework Core Cookbook - Second Edition

Product type Book
Published in Nov 2016
Publisher Packt
ISBN-13 9781785883309
Pages 324 pages
Edition 2nd Edition
Languages
Author (1):
Ricardo Peres Ricardo Peres
Profile icon Ricardo Peres

Table of Contents (15) Chapters

Entity Framework Core Cookbook - Second Edition
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
1. Improving Entity Framework in the Real World 2. Mapping Entities 3. Validation and Changes 4. Transactions and Concurrency Control 5. Querying 6. Advanced Scenarios 7. Performance and Scalability Pitfalls Index

Index

A

  • ACID properties
    • atomic / Atomic
    • consistent / Consistent
    • isolation / Isolation
    • durability / Durability
  • actual loggers / How it works…
  • Application Programming Interface (API) / Single Responsibility Principle
  • asynchronous operations
    • using / Using asynchronous operations, How to do it…
    • queries, performing for data retrieval / Queries
    • existing data, modifying / Modifications
  • atomic / Atomic
  • audit data
    • capturing / Capturing the audit data, How to do it…, How it works…
  • Azure Table Storage / Provider Model

C

  • C# POCO entities
    • generating / How to do it…
  • cache
    • using / Using the cache, How to do it…, How it works…
  • caching mechanism, in repository pattern / Repository and caching
  • cascade delete
    • reference / See also
    • about / There's more…
    / Problem
  • cascading entity deletes
    • issue / Problem
    • solving / How to solve it…
  • client-side functions
    • executing, in LINQ queries / Executing client-side functions in LINQ queries, Getting ready, How to do it…, How it works…
  • code
    • databases, creating from / Creating databases from code, Getting ready, How to do it…
  • code first approach
    • used, for improving Entity Framework / Improving Entity Framework by using a code-first approach, Getting ready, How to do it…
  • composite primary keys
    • issue / Problem
    • solving / How to solve it…
  • consistent / Consistent
  • convention over configuration approach / Convention over configuration
  • custom conventions
    • creating / Creating custom conventions, How to do it…, How it works…
  • custom SQL operations
    • transactions, using in / Using transactions in custom SQL operations, How to do it…, How it works…

D

  • DataAnnotations validations
    • reference / See also
  • database
    • updating, from model changes / Updating the database from model changes, How to do it…
    • entities, generating from / Generating entities from the database, How to do it…, How it works…
  • database-agnostic way
    • optimistic concurrency, implementing in / Getting ready, How to do it…, How it works…
  • database initializers / There's more…
  • database null semantics
    • issue / Problem
    • solving / How to solve it…
  • database profiler
    • about / Database profiler
  • databases
    • creating, from code / Creating databases from code, Getting ready, How to do it…
    • using / Using other databases, How to do it…
  • Data Transfer Objects (DTOs)
    • about / Introduction
  • date/time operations, not supported
    • issue / Problem
    • solving / How to solve it…
  • DbFunctions
    • reference / Problem
  • Dependency Injection (DI) / How to do it.…
  • Dependency Inversion Principle / Dependency Inversion Principle
  • Domain-Driven Design (DDD)
    • about / Introduction
  • Domain Driven Design (DDD) / Generating entities from the database
  • durability / Durability
  • dynamic LINQ
    • using / Using dynamic LINQ, How to do it…, How it works…

E

  • eager loading / Eager loading, How to do it…, How it works…
  • entities
    • state, setting of / Setting the state of an entity, How to do it…, How it works…
    • inserting, with stored procedures / Inserting, updating, and deleting entities with stored procedures, How to do it…, How it works…
    • updating, with stored procedures / Inserting, updating, and deleting entities with stored procedures, How to do it…, How it works…
    • deleting, with stored procedures / Inserting, updating, and deleting entities with stored procedures, How to do it…, How it works…
    • obtaining, from local cache / Getting entities from the local cache, Getting ready, How to do it…, How it works…
    • generating, from database / Generating entities from the database, How to do it…, How it works…
  • Entity Framework
    • about / Introduction
    • improving, code first approach used / Improving Entity Framework by using a code-first approach, Getting ready, How to do it…
  • Entity Framework Core
    • reference / See also
  • EntityFrameworkCore.SqlServerCompact40
    • reference / Using other databases
  • Entity Framework Core 1.0, workflows
    • code first / Generating entities from the database
    • database first / Generating entities from the database
  • Entity Framework Core site
    • reference / Using other databases
  • entity framework validation
    • MVC UI, improving with / Improving MVC UI with entity framework validation, How to do it…, How it works…
  • entity metadata
    • retrieving / Retrieving entity metadata, How to do it…, How it works…
  • Entry method, states
    • EntityState.Unchanged / How it works…
    • EntityState.Modified / How it works…
    • EntityState.Added / How it works…
    • EntityState.Deleted / How it works…
    • EntityState.Detached / How it works…
  • explicit transactions
    • using / Using explicit transactions, Getting ready, How to do it…, How it works…
  • Express Profiler
    • reference / Database profiler
    • using / Database profiler
  • extension methods / Extension methods

F

  • filtered collections
    • creating / Creating filtered collections, How to do it…, How it works…
  • First Level Cache / There's more…, Problem

G

  • Glimpse
    • about / Real time monitoring
    • reference / Real time monitoring
  • GroupBy executes, on client side
    • issue / Problem
    • fixing / How to fix it…
  • groups of entities
    • validating / Validating groups of entities, How to do it…, How it works…
  • GUID primary keys
    • about / How it works…
    • reference / There's more…
  • GUIDs
    • using, as keys / Using GUIDs as keys, How to do it…, How it works…

H

  • High-Low algorithm
    • about / Using sequence key generators
    • reference / See also
  • HTML helper / Understanding the HTML helper

I

  • Identity Map / There's more…, Problem
  • infrastructure services
    • hooking / Hooking infrastructure services
  • inheritance
    • implementing / Implementing inheritance – Table per Class hierarchy, How to do it…, How it works…
    • Table Per Hierarchy/Single Table Inheritance / Implementing inheritance – Table per Class hierarchy
    • Table Per Type/Class Table Inheritance / Implementing inheritance – Table per Class hierarchy
    • Table Per Concrete Type/Concrete Table Inheritance / Implementing inheritance – Table per Class hierarchy
  • integration tests / Integration tests
  • interfaces
    • mapping / Mapping interfaces, How to do it…, How it works…
  • Interface Segregation Principle / Interface Segregation Principle
  • Inversion of Control (IoC) / How to do it.…
  • isolation / Isolation

K

  • keys
    • GUIDs, using as / Using GUIDs as keys, How to do it…, How it works…

L

  • lazy loading / Problem
  • LINQ
    • about / LINQ
  • LINQPad / Testing
  • LINQ queries
    • client-side functions, executing in / Executing client-side functions in LINQ queries, Getting ready, How to do it…, How it works…
    • SQL, mixing with / Mixing SQL with LINQ queries, How to do it…
  • local cache
    • entities, obtaining from / Getting entities from the local cache, Getting ready, How to do it…, How it works…
  • logger factories / How it works…
  • logger providers / How it works…
  • logging
    • adding / Getting ready, How it works…
    • about / Logging
  • logging entry
    • Log Level / How it works…
    • Event Id / How it works…
    • State / How it works…
    • Exception / How it works…
    • Formatter / How it works…
  • logging providers, .NET Core
    • MICROSOFT.EXTENSIONS.LOGGING / There's more…
  • Lolita code, GitHub
    • reference / There's more…

M

  • many-to-many maps
    • creating / Creating many-to-many maps, How to do it…, How it works…
  • many-to-one relationship / Eager loading
  • mapping discriminator columns issue
    • about / Problem
    • solving / How to solve it…
  • maximum string length issue
    • about / Problem
    • solving / How to solve it…
  • Microsoft ASP.NET MVC / Model-View-Controller
  • migrations and contexts, with parameterized constructors
    • issue / Problem
    • solving / How to solve it…
  • migrations API / There's more…
  • migrations with contexts, in different projects
    • issue / Problem
    • solving / How to solve it…
  • mock database connections
    • creating / Creating mock database connections, How to do it…, How it works…
  • mocking
    • about / Unit testing and mocking, Getting ready, How to do it…, How it works…
    / Mocking
  • mocks / Mocking
  • Model-View-Controller / Model-View-Controller
  • model changes
    • database, updating from / Updating the database from model changes, How to do it…
  • Moq framework / How it works…
  • Multiple Active Result Sets (MARS) / Queries
  • multitenancy
    • about / Implementing multitenancy
    • achieving, techniques / Implementing multitenancy
    • implementing / Getting ready, How to do it…, How it works…
  • MVC applications
    • improving / Improving MVC applications, How to do it.…
  • MVC UI
    • improving, with entity framework validation / Improving MVC UI with entity framework validation, How to do it…, How it works…

N

  • naming conflict / Naming conflict
  • non-public members
    • mapping / Mapping non-public members, How to do it…, How it works…
  • NuGet package
    • reference / How it works…

O

  • Object-Relational Mapper (ORM) / Getting entities from the local cache
    • flow, for performing updates / Updates
    • flow, for performing deletes / Deletes
  • Object-Relational Mapper (ORM), models
    • POCO model / Shadow properties
    • database model / Shadow properties
    • mapping model / Shadow properties
  • Object-Relational Mappers (ORMs) / Problem
  • one-to-many maps
    • creating / Creating one-to-many maps, How to do it…, How it works…
  • one-to-many relationship / Eager loading
  • one-to-one maps
    • creating / Creating one-to-one maps, How to do it…, How it works…
  • one-to-one relationship / Eager loading
  • one class under test / One class under test
  • optimistic concurrency
    • implementing, in SQL Server / Implementing optimistic concurrency in SQL Server, How to do it…, How it works…
    • implementing, in database-agnostic way / Getting ready, How to do it…, How it works…
  • optimistic concurrency checks
    • about / There's more…
  • optimistic concurrency control failure, solutions
    • database wins / Database wins
    • client wins/last one wins / Client wins/last one wins

P

  • paging, in SQL Server
    • issue / Problem
    • solving / How to solve it…
  • paging techniques
    • reference / How to solve it…
  • performance
    • improving, of queries / Improving the performance of queries, Getting ready
  • Plain Old CLR Object (POCO) / Generating entities from the database
  • Plain Old CLR Objects (POCOs) / Introduction
  • projects, available for code-first approach
    • BusinessLogic / Improving Entity Framework by using a code-first approach
    • DataAccess / Improving Entity Framework by using a code-first approach
    • UI / Improving Entity Framework by using a code-first approach
    • UnitTests / Improving Entity Framework by using a code-first approach
  • property changes
    • intercepting / Intercepting property changes, How to do it…, How it works…
  • Provider Model / Provider Model

Q

  • queries
    • performance, improving of / Improving the performance of queries, Getting ready
    • testing / Testing and profiling queries, How to do it…
    • profiling / Testing and profiling queries, How to do it…
  • Query Object pattern
    • implementing / Implementing the query object pattern, How to do it…, How it works…
  • query performance, improving ways
    • modifications / Modifications
    • queries / Queries

R

  • real time monitoring / Real time monitoring
  • Redis / Provider Model
  • refactor / Refactoring
  • references not eagerly fetched are lost issue
    • about / Problem
    • solving / How to solve it…
  • refreshing entities
    • issue / Problem
    • solving / How to solve it…
  • relationships
    • reference / See also
  • repository pattern
    • implementing / Implementing the repository pattern, How to do it…, How it works…
    • caching mechanism / Repository and caching
    • reference / See also
  • reusable queries
    • creating / Creating reusable queries, How to do it…, How it works…

S

  • saving changes
    • intercepting / Intercepting saving changes, How to do it…, How it works…
  • scaffolding / Generating entities from the database
  • SELECT N+1 problem / Eager loading
  • sequence key generators
    • using / Using sequence key generators, How to do it…
  • server-generated GUIDs
    • using / There's more…
  • Server Process ID (SPID) / Database profiler
  • service provider access
    • issue / Problem
    • solving / How to solve it…
  • shadow properties
    • about / Shadow properties, How to do it…
    • working / How it works…
    • reference / See also
    • querying / Querying shadow properties, How to do it…, How it works…
  • simple properties
    • validating / Validating simple properties, How to do it…, How it works…
  • Single Responsibility Principle (SRP) / Single Responsibility Principle
  • soft deletes
    • handling / Getting ready, How to do it…, How it works…
  • SOLID principles / Single Responsibility Principle
  • SQL
    • mixing, with LINQ queries / Mixing SQL with LINQ queries, How to do it…
    • about / SQL
  • SQL script
    • dumping, for database creation / Dumping the SQL script for the database creation, How to do it…
  • SQL Server
    • optimistic concurrency, implementing in / Implementing optimistic concurrency in SQL Server, How to do it…, How it works…
  • state
    • setting, of entities / Setting the state of an entity, How to do it…, How it works…
  • stored procedures
    • entities, inserting with / Inserting, updating, and deleting entities with stored procedures, How to do it…, How it works…
    • entities, updating with / Inserting, updating, and deleting entities with stored procedures, How to do it…, How it works…
    • entities, deleting with / Inserting, updating, and deleting entities with stored procedures, How to do it…, How it works…
  • strongly typed bulk operations
    • about / Strongly typed bulk operations, Getting ready, How to do it…
    • deletes / How it works…
    • updates / How it works…
  • stubbing / Mocking

T

  • table per class hierarchy, requiring nullable columns for derived class
    • issue / Problem
    • solving / How to solve it…
  • Table Per Class Hierarchy/Single Table Inheritance pattern / Problem
  • Table Per Concrete Type/Concrete Table Inheritance / Implementing inheritance – Table per Class hierarchy
  • Table Per Hierarchy/Single Table Inheritance / Implementing inheritance – Table per Class hierarchy
  • Table Per Type/Class Table Inheritance / Implementing inheritance – Table per Class hierarchy
  • testing / Testing
  • transactions
    • using, in custom SQL operations / Using transactions in custom SQL operations, How to do it…, How it works…
  • transactions, extension methods
    • BeginTransaction/BeginTransactionAsync / How it works…
    • UseTransaction / How it works…
  • transactions, methods
    • BeginTransaction/BeginTransactionAsync / How it works…
    • CommitTransaction / How it works…
    • RollbackTransaction / How it works…

U

  • unit of work pattern
    • implementing / Implementing the unit of work pattern, How to do it…
    • reference / Implementing the unit of work pattern
    • call per change / Call per change
  • unit testing
    • about / Unit testing and mocking, Getting ready, How to do it…, How it works…
    • Arrange, Act, Assert / Arrange, Act, Assert
  • user interface (UI) layer
    • about / Improving Entity Framework by using a code-first approach

V

  • validation attributes, System.ComponentModel.DataAnnotations
    • CompareAttribute / There's more…
    • CreditCardAttribute / There's more…
    • CustomValidationAttribute / There's more…
    • DataTypeAttribute / There's more…
    • EmailAddressAttribute / There's more…
    • EnumDataTypeAttribute / There's more…
    • FileExtensionsAttribute / There's more…
    • MaxLengthAttribute / There's more…
    • MinLengthAttribute / There's more…
    • PhoneAttribute / There's more…
    • RangeAttribute / There's more…
    • RegularExpressionAttribute / There's more…
    • RequiredAttribute / There's more…
    • StringLengthAttribute / There's more…
    • UrlAttribute / There's more…

W

  • where generic constraint / Where generic constraint
  • whole entity
    • validating / Validating the whole entity, How to do it…, How it works…
  • workflows, for working with Object-Relational Mapper (ORM)
    • database first / Introduction
    • code first / Introduction

X

  • xUnit runner / How to do it…

Z

  • Z.EntityFramework.Plus package / There's more…
lock icon The rest of the chapter is locked
arrow left Previous Chapter
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}