Allowing duplicate keys in language's BSON representation

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Won't Fix
    • Priority: Major - P3
    • 12_01_17
    • Affects Version/s: None
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      What is the best way for us to represent documents like the following in Ruby, Python, PHP, etc.

      db.posts.find( { keywords :

      { $in : ["a", "b"] }

      , keywords :

      { $in : ["c, d"] }

      } )

      Options:

      Use a JSON string.
      Create a hash/dict subclass that allows duplicates.
      Come up with some other way of writing this in a dictionary: { $dup: { key: "keywords", values: [

      { $in: [ "a", "b" ] }

      ,

      { $in: [ "c", "d" ] }

      ] } }

      • either translate at the driver level or support this in the server.

            Assignee:
            Michael Dirolf (Inactive)
            Reporter:
            Michael Dirolf (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: