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

Add Support For GUID in ToString representation of a cursor

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • None
    • None
    • None
    • None

    Description

      Currently, when calling ToString() on a cursor, if it includes a Guid, the resulting output looks something like:

      CSUUID("f7402520-3018-4b8e-9414-4d93a244f9b0")
      

      We should add a shell friendly version of this output. At its most basic it is as simple as converting to a byte array then to a base64 encoded string.

      var str = $"new BinData(3, \"{Convert.ToBase64String(guid.ToByteArray())}\")";
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            peter.garafano@mongodb.com Peter Garafano (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: