I am trying to import data into a new database, but some of the columns in the old database are null.
In one of my methods, I am using the query below to get the records, like I said already there is a column in the rows which has a null value for some records.
Guid nameGuid= new guid('CCECE54B-EE14-4463-8A0B-02C72679334A')
MySubQuery = from a in MainQuery
where a.Table1.Id.Equals(nameGuid)
Select a;
I want to check for a.Table1.Id value, if it is equal to null, then I still want the row but ignore the where condition.
Any suggestion for using the ternary operator in Linq query or any other approaches for my task.