Business Logic to LINQ
I was hoping someone could point me to a good article about adding business logic to LINQ. Right now I've seen multiple ways to do it with partial classes, however, in a development environment where the database seems to constantly be changing the only way to update LINQ is to delete/add the tables from the columns other than manually editing every change. Is there a better solution or possibly a workaround that I'm unware of?
Scott LyslePosted Jun 11, 2008, 6:14 AM
The easiest way to update the model is just to remove and replace the tables when they change. You can provide implementations for the extension methods in partial classes for the basic crud type functionality. Other business logic can be placed in classes that run other LINQ to SQL queries against the model; not that it is necessarily the way to do it, I have tended to keep the business logic together in a class library and not bother with the extension methods.