A perfect blend of all things Dot Net
I’m still reading the excellent C# 3.0 in a Nutshell: A Desktop Quick Reference (In a Nutshell (O’Reilly)), by Ben and Joseph Albahari. It answers a popular question: how do I use a DataContext object in LINQ within a multi-tier application?
According to the authors, you cannot use the DataContext at an application or static level, or use a single instance for all requests, as it is not thread-safe. It has to be recreated for each request.
I need to look into this more.
Dragan Panjkov
May 26th, 2008 at 3:13 pm
any news regarding this?
Taink
July 24th, 2008 at 7:03 pm
I believe there is more info on this at linqhelp.com