Uploaded image for project: 'C# Driver'
  1. C# Driver
  2. CSHARP-430

LINQ does not support DateTime comparisons

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • 1.4.1
    • 1.4
    • None

    Description

      Following exception occurs when applying a comparison operator on a field of type DateTime:

      Unsupported where clause: (DateTime:(2012-04-03T12:45:32.5348776Z) < s.CreatedOn)

      The query is as follows:

      .Where(s => DateTime.UtcNow < s.ExpireOn)

      Note: This is supported by FluentMongo

      Attachments

        Activity

          People

            robert@mongodb.com Robert Stam
            zaidmasud Zaid Masud
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: