Search code examples
c#linqlinq-to-sql.nettiers

Should I start using LINQ To SQL?


Currently I am using NetTiers to generate my data access layer and service layer. I have been using NetTiers for over 2 years and have found it to be very useful. At some point I need to look at LINQ so my questions are...

  1. Has anyone else gone from NetTiers to LINQ To SQL?
  2. Was this switch over a good or bad thing?
  3. Is there anything that I should be aware of?
  4. Would you recommend this switch?

Basically I would welcome any thoughts .


Solution

    1. No
    2. See #1
    3. You should beware of standard abstraction overhead. Also it's very SQL Server based in it's current state.
    4. Are you using SQL Server, then maybe. If you are using LINQ for other things right now like over XML data (great), Object data, Datasets, then yes you should could switch to have a uniform data syntax for all of them. Like lagerdalek mentioned if it ain't broke don't fix it. From the quick look at .netTiers Application Framework, I'd say if you already have an investment with that solution it seems to give you much more than a simple Data Access Layer and you should stick with it.

    From my experience LINQ to SQL is a good solution for small-medium sized projects. It is an ORM which is a great way to enhance productivity. It also should give you another layer of abstraction that will allow you to change out the layer underneath for something else. The designer in Visual Studio (and I belive VS Express also) is very easy and simple to use. It gives you the common drag-drop and property-based editing of the object mappings.

    @ Jason Jackson - The Designer does let you add properties by hand, however you need to specify the attributes for that property, but you do this once, it might take 3 minutes longer than the initial dragging of the table into the designer, however it is only necessary once per change in the database itself. This is not too different from other ORMs, however you are correct that they could make this much easier, and find only those properties that have changed, or even implement some kind of refactoring tool for such needs.

    Resources:

    Note that Parallel LINQ is being developed to allow for much greater performance on multi-core machines.