1

I was under the impression that when using in memory LINQ as below that TimeSpan is able to be used. If this is not the case how do I convert TimeSpan to date then? Note I believe entities in an in memory list.

var charterRequestDtoIds = from e in entities.Where(e => e.ClientId == clientId
                                        && e.Status != TrackingState.Void
                                        && DateTime.Now < DbFunctions.AddDays(e.CreatedAt, e.BiddingToCloseIn.Days + 30))
                                    select(e.Id);

The Error:

System.NotSupportedException: The specified type member 'BiddingToCloseIn' is not supported in LINQ to Entities. Only initializers, entity members, and entity navigation properties are supported.

Jason Boyd
  • 6,839
  • 4
  • 29
  • 47
RickyTamma
  • 182
  • 3
  • 13

0 Answers0