I’m having trouble adding a “where x in (select …)” statement to my linq query.
The query represents a Master [MEDIEN] / Detail [EXEMPLARE] scenario.
The missing where statement should represent the following SQL:
WHERE e.EXEMPLARSTATUS IN (SELECT EXEMPLARSTATUS FROM ANYTABLE)
Dim eMedien = ( _
From p In db.MEDIEN _
Where p.MEDIENNR = "1235155"
Select New With {.HST = p.HST,
.ANYNAME = ( _
From e In p.EXEMPLAR _
**** WHERE QUERY ****
Select New With {.ZWEIGSTELLE = e.ZWEIGSTELLE, .EXEMPLARSTATUS = e.EXEMPLARSTATUS})
})
Any help is apreciated!
This part of your query should be written as