tags:

views:

252

answers:

5

In my humble opinion, Microsoft is changing rules about database managing each four or five years. I remember old days when RDO was the solution to connect to SQL server. I refresh my knowledge to use ADO because RDO was obsolete. ADO was very good and effective, but not so long ago, I found myself programming and refreshing again my knowledge to use ADO.NET. Now I'm working in my first project using LINQ.

¿What's your opinion? It's LINQ ready to be the next standard or I should wait and continue to use ADO.NET as in .NET 2.0? I need to know from your own experience if changing to LINQ is not too expensive compared with the benefits it offers.

Thanks in advance for your answers.

+2  A: 

Should clarify that ado is used to retrieve data, linq is a query lanugage, you have to use both, they're not the same. Linq to Sql gives you a data access layer, which might be what you're talking about but Microsoft already announced dropping support for it and going with Linq to Entities. Should you wait, No. They'll just come out with LinqToEntitiesADO.NET# tomorrow!

Joshua Belden
+2  A: 

LINQ is only incidentally about databases. It's really Microsoft's idea of a more comprehensive abstraction for structured data access in general. But since it's first manifestation was LINQ-to-SQL, that's the first perception people have had. And of course developers, especially those not too comfortable with SQL, have loved it.

But I'd consider it more an alternative to SQL than to the other items you mentioned.

Should you start using LINQ? I'd say first read the Microsoft site info and see if you agree with it conceptually. I think it's a good conceptual idea, Microsoft has bright people working on it, and there's not much competition. So as long as you're firmly on-board as .NET organization, you'll probably like it. There's some indication that the non-Microsoft world will eventually join too, timing undetermined.

le dorfier
A: 

Considering the rate at which computer software changes, I certainly hope that Microsoft changes the rules more frequently than every four or five years!

You can wait of course. If you're going to wait, I suggest you wait until the turn of the Century. That way you'll have little chance of having to learn anything new.

John Saunders
+6  A: 

Should you wait for what? If you think about it, any code you would have written in the past would work equally well today as it did then. Is LINQ more productive than most of those earlier methods? In my opinion, yes, but then I really like LINQ. Is Linq To Entities better? No, its just different and to be honest, in many cases its quite a bit more worked. The IJW ( it just works! ) factor of LINQ is truly incredible, its one of the most elegant technologies to come out of Microsoft in a very long time. Will there be something better in the future? Most likely. But we live and code in the present and waiting for the future is a fools errand as there is always something better just over the horizen.

That said, this is a good argument for abstraction. When you design your classes ask yourself, could I replace X ( Linq, ADO.Net, etc... ) in my data layer without breaking the rest of my application? If you can answer yes, you probably have a pretty good design. Doing a proper data layer really isn't that hard and it allows you the flexibility to switch out from Linq, to any other ORM ( Link to Entities, nHibernate, etc... ) or even to switch to a completely different back end like Web Services, or whatever the next great thing is.

Also, if it puts your mind at ease, LINQ isn't going anywhere. Its part of the language, is being implemented in mono and more linq providers are being added. Even if Microsoft moves to a different technology, you will still see people using and supporting Linq. Hell, its already happened to some degree with Linq to Entities and you still see the majority of developers using Linq will mostly ignoring L2E. The only major downside to using LINQ today is the lack of a solid MySQL/PostOgre linq provider freely available, but there are some in the works.

Serapth
+2  A: 

LINQ as a Language feature will "never" (never say never right) go away, so learn it. It potentially allows you to query any data structure. i.e. you can use LINQ to query LINQtoSQL Entities, XML, DataSets etc etc.

However, if you're talking about LINQ to SQL specifically, then I kinda agree with you.

Less than 2 years ago, LINQ to SQL was here to stay. Now its been dropped in favour of the Entity Framework.

Now, yes, they've said a lot of LINQ to SQL features will be integrated into the Entity Framework, but nonetheless, LINQ to SQL, as so many have adopted, has been dropped, and there certainly was still a lot of room for improvement.

Check the comments here for similar concerns.

andy