All my documents have a structure like this: { operational: {availableFleet: [Objectid('5bad3f452641a1186d21b5f8'), ...]} } So every document has an operati
I'm hoping someone can help: I have MongoDB collection for a User which has an Array called Reports which holds objects with IDs. I can retrieve the IDs but I'm
Here is, my code. i want to add a spinner when data is loading then after finish loading display the data. {/* product section */} <section className="c
So I have two schemas user and driver they both have latitude and longitude attributes. At some point I want to query the database for nearby drivers, I will be
The following query is erroring out: const pastOrders = await Order.find( {user: userId}, {status: {$in: ["delivered", "refunded"]}} ).popul
I am trying to build a CRUD API that query a mongodb. I want to add another attribute (temperature) to the query result before sending it back to the client. Pa
I'm building a simple MERN blogging app with a local MongoDB. Everything was working fine until yesterday. I literally changed nothing at all and now I can't co
I have an app with MongoDB (Mongoose) in NodeJs. In a collection I have this type of documents, defined by weeks: { "_id": {"$oid":"617f3f51f883fab2de3e7260"},
I have just write post method for inserting data in MongoDB.when submit form for fetch data form frontend that time gets this error List item net::ERR_CONNECTIO
I've been trying for over 2 hours now trying to figure out what's wrong with this database. I've tried everything. From reinstalling the server, restarting the
I have seen this issue published in a few places however I still don't have a solution. I am using a node server and can connect to my database correctly with a
I'm learning about sharding approaches. How to achieve good horizontal scalability with a large number of shards in an IO-heavy application. Below I describe a
I am trying to render a page with something I load from MongoDB: router.get('/messages', async (ctx, next) => { await MessageModel.find() .then((resul
Get request method in tasks.js file const { Task } = require('../model/Tasks.js') const asyncWrapper =require('../middleware/async') const getTask = asyncWrapp
We have a requirement to insert to the sub array when sub array contains some value, but I get an error when using push with arrayFilter: fail to run update: w
I can use the following for exact matches on loosely typed data in MongoDB: var mongoClient = new MongoClient(con); IMongoDatabase mongoDatabase = mongoClient.G
I have data and need to group by two fields and in response display unique filed along with the count on this field. Sample data: [ { "categoryCode":"c
Its's nice to see mongodb is connected with django but doesn't support completely. I explain why so because when you install any third party packages to your pr
I have working on my final year college project On MERN stack. my problem is mentioned bellow please help me. const Organization = mongoose.Schema({ name: {
Obligatory - I know this question has been asked before, but answers back then relate to the old mongoldb driver, I'm using the pecl mongodb php library. The ai