Add condition to LINQ LET query?
===


I'd like to be able to add an if statement into a linq query to add a second LET.  Does anyone know if this is possible?  Thanks 

    var query = from d in myList
    group d by d.Date
    into v
    let dataSum = nv.Sum(x => x.Data)
    select new MyObject(){ Date = nv.Key.Date, Data = dataSum}
    
    var query = from d in myList
    group d by d.Date
    into v
    let dataSum = nv.Sum(x => x.Data)
    if(secondaryData){ let dataSum2 = nv.Sum(x.Data2)}
    select new MyObject(){ Date = nv.Key.Date, Data = dataSum}