Advantage and Disadvantage of LINQ:-
Advantage
There are many advantages of LINQ:-
Disadvantage
There are many disadvantages of LINQ:-
There are many advantages of LINQ:-
- LINQ has full type checking at compile-time and IntelliSense support in Visual Studio. This powerful feature helps you to avoid run-time errors.
- LINQ supports various powerful features like filtering, ordering and grouping with minimum code.
- LINQ also allows debugging through .NET debugger.
- LINQ provides a uniform programming model (i.e. common query syntax) to query data sources (like SQL databases, XML documents, ADO.NET Datasets, Various Web services and any other objects such as Collections, Generics etc.)
- LINQs Query can be reused.
Disadvantage
There are many disadvantages of LINQ:-
- LINQ doesn’t take the full advantage of SQL features like cached execution plan for stored procedure.
- LINQ performance is degraded if you don't write the LINQ query correctly.
- LINQ is not good to write complex queries like SQL.
- If you have done some changes in your query, you have to recompile it and redeploy its dll to the server.