ef4-code-only
EF4 CTP5 self-referencing hierarchical entity mapping
Okay, this should be really easy, but I\'ve been tearing my hair out.Here\'s my POCO (which has to do with machine parts, so a part can be contained within a parent part):[详细]
2023-02-02 12:38 分类:问答MVC, ViewModels, and Validation
I\'m creating an MVC3 application with EF4 using POCOs. I\'ve added validation attributes to my EF entities. Now, as I\'m building the views, I want to use a view model (and perhaps use AutoMapper to[详细]
2023-02-02 01:44 分类:问答Register generic type in DbContext EF4 CTP5
in EF4 CTP4 we had RegisterSet function to 开发者_StackOverflow社区generically register entity in ModelBuilder. We used Configurations.Add() to register the mapping for entities. How to achieve this E[详细]
2023-01-29 23:31 分类:问答Code-First: How to create a many to many relationship where the source class/table is the target one as well?
Can someone please post an example on how to create a many to many relations开发者_运维知识库hip where the source class is also the target one, using code-first ?[详细]
2023-01-29 02:46 分类:问答How do I recreate DB using EF4 code first for test
I\'m using Entity Framework 4 Code First in my .net MVC 2.0 project and I\'m having hard times to get my DB sync with my Entities. What I want is a page that I can call, as an exemple : /DB/Recreate,[详细]
2023-01-27 05:34 分类:问答How does EF 4 code first handle schema changes in a production environment?
Traditionally I have always written my sql scripts by hand so they are nice and clean (I\'m not a fan of the generated ones) and release to release, I provide a fresh install script and a migration sc[详细]
2023-01-25 10:03 分类:问答EF4 Code Only + Ria Services
I thought I could use my DbContext with a DomainService just the same way I use it with any MVC app: public class DatabaseContext : DbContext[详细]
2023-01-25 04:19 分类:问答Junction table with additional columns in EF4 CTP4 Code First
Given this sql schema: create table [dbo].[Courses_Students] ( [DummyColumn] [int] null, [CourseId] [int] not null,[详细]
2023-01-24 13:07 分类:问答EF4 Code Only - Map Columns to Property Complex type
I have a table like this: Name Tree Iron Clay 开发者_Go百科Added I want to map it to a model like this:[详细]
2023-01-23 09:45 分类:问答how do i create a composite key that comprises a foreign key with code first?
I am using EF4 code first and want to generate a composite key which is made of a class property and foreign key. I have two classes: Order and Company. The Order class holds a reference but this will[详细]
2023-01-20 23:14 分类:问答