I have a list of tuples (List<Tuple<string,string>>
) of Fname
and Version
as input.
eg.
[('firstname1','1.0.1'), ('firstname2','2.3.3'), ('firstname3','4.4.1')]
Is it possible to write a LINQ query that essentially does what the following SQL query does and returns tuples of Name
and AttribX
?
SELECT e.Name, a.AttribX
FROM Element e
JOIN Attributes a ON a.AId=e.EAId
where (a.FName='firstname1' and a.Version='1.0.1')
OR (a.Fname='firstname2' and a.Version='2.3.3')
OR (a.Fname='firstname3' and a.Version='4.4.1')
There are about a 1000 tuples in the input.