I am trying to figure out something with EF4 Code Only. If i use TPH and i wanted to change a saved Person to Instructor or vice versa, how would i accomplish this. My POCO classes:
public class Person
{
public int PersonId { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
}
publi...
My problem is that when I add a new entity with a required field, the entity doesn't show the validation error in the UI. I'm using using EF CTP4 Code First. My setup :
I have an entity.
public class Category
{
[Key]
public int Id { get; set; }
[Required]
public string Name { get; set; }
public string ImageUrl ...
Hi I am using Entity Framework code only from CTP4. My question is this: given the name of a domain class which is mapped using an EntityConfiguration how can I retrieve the table name for the mapped class at runtime? I'm assuming I need to be using the MetadataWorkspace on the ObjectContext, but finding it difficult to get up-to-date ...
I am having a lot of trouble with 'base types' in the Code Only model of the Entity Framework. I am having a lot of trouble with 'base types' in the Code Only model of the Entity Framework.
When I try to run this code using a DbContext with a DbSet<Template>, I get the following error.
A The navigation property 'Flags' is mapped t...