Tuesday, 12 August 2014

LINQ - An Attempt at Tackling Impedance Mismatch

Origins of the Term Impedance Mismatch

Impedance mismatch is a term borrowed from the process of impedance matching in electronics. Electrical impedance measures the opposition that a circuit presents to a current when a voltage is applied.

Object-Relational Impedance Mismatch

The object-relational impedance mismatch describes the style differences required to code queries to relational database systems from OO languages.

For starters, SQL queries violate the rule of encapsulation.

LINQ tackles this by making relational queries part of the C# language. As a bonus, it also allows you to do similar queries on .NET objects.

LINQ is regarded as a Fundamental Part of C# (One of the default namespaces of System.Dll)

Proof of this is given by the "using System.Linq;" module import message that is inserted by default, by Visual Studio, at the start of your C# program (other default includes include System, System.Text and System.Collections.Generic).

No comments: