How to store images using Entity Framework Code First CTP 5?

I always create another class like ProductImage with a one-to-one association in order to manage lazy loading and also to normalize the table:

public class ProductImage
{
    public int ProductId { get; private set; }
    public byte[] Image { get; set; }
}

Leave a Comment