FAQ Database Discussion Community

How to update related entities using GraphDiff?

I have the following model: public class Customer { public int Id {get; set;} public string Name {get; set;} public int AddressId {get; set;} public virtual Address Address {get; set;} public virtual ICollection<CustomerCategory> Categories {get; set;} } public class CustomerCategory { public int Id {get; set;} public int CustomerId {get;...

Resolving class that has extension methods with AutoFac

I am using a third party library GraphDiff which adds Extension methods to DBContext class. My Context class is inherited from Interface like following MyContext: DbContext,IMyContext IoC contained register MyContext as IMyContext. Interface doesn't have extension method's signature and third. Now i am not getting how MyContext will have that...

Can GraphDiff be used for partial updates of simple entities too?

I have a WebApi2 project with EF6 CodeFirst. I'm also using AutoMapper to map between my models and dto's. I'm not using OData. I'm trying to find a solution to handle updates of entities. As I'm not using OData I can't use Delta and I would not like to use...