I have two list of Ids named List<Guid> A and List<Guid>B, For list A i want to set Update.Set("IsPending", True) and for List B i wan ...
I have two list of Ids named List<Guid> A and List<Guid>B, For list A i want to set Update.Set("IsPending", True) and for List B i wan ...
I'm trying to get the value from articlePrice only. But also get the attribute name. How do I fix that? MAX: { articelPrice: 560.5 } MIN: { arti ...
I have a MongoDB with 3 collections. Here are the 3 collections each with an example of a document it contains: tag computer setting As ...
Considering I have a users collection contains those documents: { _id: 1, hobbies: ['eat', 'read', 'swim'] }, ...
I am centralizing data on my Atlas Cluster from bare-metal servers running community MongoDB databases locally. However I have an issue with my ISODat ...
my data structure is and products elements all tags in empty I need to add a value to mongo db inner object with array element without looking at oth ...
I have the following Mongoose schema as defined on this page Now I want to create a virtual on AuthorSchema to get the BlogPosts which have comment ...
Whats the proper approach for the above if I cant use $where ? How can I compare an ISO date based on its day and month only. What if i want to find p ...
I can't get my create resolver to return the newly created document. It returns null for all values. Here's the code: RESOLVER // SECTION SCHEDU ...
I've got let's say one collection "users": And now I have "updates" collection: All have common User.id field. Now I'm trying to get data from ...
I have a Mongo collection of states, where each state contains an array of cities: I need an update query that will lowercase every cities.name in ...
I want to get the user details for a db using go driver. For ex. in mongoshell How do i construct a bson.M or bson.D for this ? I don't want to p ...
In the $lookup stage of my aggregation pipeline, it needs to join based on _id, which is indexed on the joined collection. The purpose is to simply ch ...
Assumption: All data and indexes are in RAM. First query: Second query: My reasoning: The second query should be faster because the $in ...
Do indexes always persist on RAM? Hence, does scanning indexes require first retrieving the index from disk? EDITED: My questions is more abo ...
In mongo db, I have the input collection Collection name - dirPermission and sample record [ { dirId: "1", dirName: "firstDir", u ...
I have records like this I want to active something like this, if i give a filter {val:"1"} i want to be able get 50%(rounded up) random results. f ...
I have the Mongo documents with the following structure: The media field is an array. How can I convert the media array type field into the object ...
I have a collection with values associated to the sells of (almost a million) different products by day, and I have to create the collection with the ...
Need some help to figure out why nested bson.M doesn’t work occasionally in FindOne(). For the following Golang structs stored in a MongoDb collectio ...