Recommendation about insert/update/delete operations with Linq to SQL

Recommendation about insert/update/delete operations with Linq to SQL

Old forum URL: forums.lhotka.net/forums/t/5128.aspx


jgamba posted on Sunday, July 20, 2008

Greetings to everyone, I am novice, is my first speech, I am a great admirer of Rocky and many of you.

I'm starting with CSLA and I am interested in its relationship with LINQ. I have read quite a few threads here on the subject,
For example this Rocky's post

http://forums.lhotka.net/forums/permalink/19939/19939/ShowThread.aspx#19939

But can not find consensus on the best method to insert, update and delete using LINQ.

I know a method which is currently used in ProjectTracker (Stored procedures), but I have also seen that the host has LINQ objects with their change notifications.

I am inclined by the second method, however, I know that it has the problem of serialization.

Please give me your opinion, what is the best method? why? if the second, could provide a concrete example (code) of how to attach and manage change notifications at
deserialize time?

In advance thank you very much for the help they can provide.

jgamba replied on Monday, July 21, 2008

Ok, I was researching and among others, I found some interesting links like these:

http://forums.lhotka.net/forums/permalink/24474/24474/ShowThread.aspx#24474
http://msdn.microsoft.com/en-us/library/bb546187.aspx

These already clarified part of my doubt about how use more objects LINQ that SPROCs.

But, Yet there remains concern about opinion

Which is best? SPROCs or objects using LINQ?

What reasons behind their choice? advantages and disadvantages, performance, object oriented, maintainability, consistent with CSLA?

Especially, I want a response from Rocky, or someone who knows their plans, about which of the two methods fits more with the future of CSLA and ADO.Net Entity Framework.

Again, I appreciate the help they can provide.

Copyright (c) Marimer LLC