I\'m using EF4 Code First and I have a property:
public byte[] Bytes {get;set;}
can I make this property load lazily ( onl
Table spliting works in EF 4.1 RC:
public class Item
{
public int Id { get; set; }
...
public virtual ItemDetail ItemDetail { get; set; }
}
public class ItemDetail
{
public int Id { get; set; }
public byte[] Bytes { get; set; }
}
public class Context : DbContext
{
public DbSet- Items { get; set; }
public DbSet
ItemDetails { get; set; }
protected override void OnModelCreating(DbModelBuilder modelBuilder)
{
base.OnModelCreating(modelBuilder);
modelBuilder.Entity- ().ToTable("Items");
modelBuilder.Entity
().ToTable("Items");
modelBuilder.Entity- ()
.HasRequired(i => i.ItemDetail)
.WithRequiredPrincipal();
}
}