خرید بک لینک

Vote count: 0

Here is what the data looks like:

{
    "_id" : {
            "item" : "1",
            "state" : "something"
    },
    "things" : {
            "ordered" : 2,
            "cost" : 123
    }
}

I try to query for all doc of item 1, there are many state for that item. I know i can get that record using db.orders.find({_id:{item:"1", state: "something"}}). But I would like to get all states I try something like db.orders.find({_id:{item:"1", state: {$exists: true}}})

But that doesn't seem to work. What am i doing wrong?

asked 54 secs ago

برچسب: نویسنده: استخدام کار تاريخ: شنبه 25 ارديبهشت 1395 ساعت: 3:24

صفحه بندی