mario.muja wrote:
Hi,
is there anything in LLBLGen similar to the Update() method of an ADO.NET SqlDataAdapter?
We think about using an O/R mapper but we also think about how we can synchronize changes in offline scenarios where a user disconnects from a server and later reconnects and replicates his data.
The Update() method automatically reconizes which record is new, changed, deleted. But when using LLBLGen, we would have to recode this behaviour using events or triggers, right?
No, you don't have to do that
Entities track their own changes. So you can just load some entities, send them to a remoted client, there they're modified, and when they come back you just save them.
You can also use a UnitOfWork object, which is serializable, to which you can add entities to be deleted as well. You then send the UnitOfWork to the server and commit it. All actions recorded with that unitofwork object are then executed in a transaction.