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

FilterDefinition don't respect GuidRepresentation

    • Type: Icon: Bug Bug
    • Resolution: Gone away
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 2.11.0
    • Component/s: API
    • None
    • Environment:
      dotnet core 3.1 on Linux and Windows
    • None
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?
    • None
    • None
    • None
    • None
    • None
    • None

      I replace BsonDefaults.GuidRepresentation = GuidRepresentation.Standard; by BsonSerializer.RegisterSerializer(new GuidSerializer(GuidRepresentation.Standard)); to set all my app use Standard representation, 

       

      But if I do Builders<MyEntity>.Filter.Eq("_id", myGuid);, the filter is translated with CSUUID(...) in place of UUID(...).

       

      In more largest case, how I can specify Guid representation with this type of filter ? 

        1. image-2021-03-11-14-30-27-628.png
          24 kB
          Michał Makowski
        2. image-2021-03-11-14-30-33-167.png
          24 kB
          Michał Makowski

            Assignee:
            Unassigned Unassigned
            Reporter:
            herve.tinant@gmail.com Hervé TINANT
            Votes:
            2 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: