Friday, December 2, 2011

Entity Framework TPT Performance Quick Tips

  1. When using model-first, choose TPH over TPT when possible.
  2. When using database-first, remove navigation properties from corresponding entities. Obviously there’s a tradeoff here, but to get TPT to a reasonable performance the sacrifice is necessary.
  3. Create views of corresponding tables and create entities on the views.

0 comments:

Post a Comment