Are Multiple DataContext classes ever appropriate?

后端 未结 5 1958
别跟我提以往
别跟我提以往 2020-12-17 08:19

In order to fully use LinqToSql in an ASP.net 3.5 application, it is necessary to create DataContext classes (which is usually done using the designer in VS 2008). From the

5条回答
  •  别那么骄傲
    2020-12-17 08:28

    I'd been wrangling over the same question whilst retro fitting LINQ to SQL over a legacy DB. Our database is a bit of a whopper (150 tables) and after some thought and experimentation I elected to use multiple DataContexts. Whether this is considered an anti-pattern remains to be seen, but for now it makes life manageable.

提交回复
热议问题