Category "mongodb"

When run node js application getting error whitelist ip in mongo cluster

I have implemented node js application and used MongoDB as database using nginx to run the project Everything working fine in local but when code is published i

NextJS: load global plugin in Mongoose before model creation

I have a folder structure looking something like this root/ pages/ models/ User.js utils/ plugin.js dbConnect.js I want to be able to load th

Copy nested array into plain one when it is only empty

How do I copy one nested array (urls2.url_breed) into an empty array url_alternative only if this one is empty like in this case? There are some cases when it i

BsonSerializationException: Creator map for class has 2 arguments, but none are configured

I have a TextSearchJob object to store on MongoDB. I am rather new with the database and I don't know why I have this error with the IDictionary version (on the

In mongoose I have executed the example program given in the website but I'm getting the same error that is: TypeError: fluffy.speak is not a function

const mongoose = require('mongoose'); main().catch(err => console.log(err)); async function main() { await mongoose.connect('mongodb://localhost:27017/t

MongoDB python connection

I just upgraded my mongoDB subscription and suddenly I get this error everytime I try to connect: -shard-00-02.dlu0y.mongodb.net:27017: [SSL: CERTIFICATE_VERIFY

Index on oplog.rs

Is there any impact creating an index on oplog.rs on the following fields {"ns": 1, "op": 1, "ts": 1} to improve the query on those fields that causing a lot of

Error: Cannot init client | mongo-connect express-session

I am getting error while trying to save session on mongodb. Here is my code.. const express = require("express"); const session = require("express-session"); co

How can we report to our customers that the orders are closed in our react native app?

I am making a react native app to deliver homemade snacks by taking orders the previous day. Whenever I am not available, how can I notify my customers that I c

Why MongoDB saves Hash value in different format?

I am learning IPFS and trying to save IPFS file info in MongoDB. After uploading, I get one hash value ex: {fileHash: CID(QmbCaWPi9tSqcnykvBUMaH2M1d5PiVPLEfPwhJ

Node js SyntaxError: Unexpected token 'export'

I'm having the following error in the console when I try to run my api written in node js. Can you tell me which is the problem.

com.mongodb.MongoSocketOpenException: Exception opening socket with spring boot and mongodb cloud

Please suggest any solution for the below exception which is occuring while running my rest api while executing springboot application with mongodb cloud db. I

Does the return value of a MongoDB Atlas trigger function have meaning?

In MongoDB Atlas, you can create triggers. These allow javascript functions, with access to the Mongo database, to respond to events. (See the docs at https://w

MongoNotConnectedError: MongoClient must be connected to perform this operation. How to handle this error?

cmd How can i solve this. Just showing MongoClient must be connected to perform this operation at getTopology ..... at collection.insertOne .... at maybePro

Error while 'composer require jenssegers/mongodb' adding MongoDB to new Laravel 7 Project

After fresh installation of laravel 7 project, C:\xampp\htdocs\blog>composer require jenssegers/mongodb --ignore-platform-reqs But this is giving an error

Why the data resets after save in database?

I'm trying to save new phone number in database First by another method get phone number and temporary save it and send a code to user then by following methods

How to map with the help of Automapper (TypeScript) the entries of an array filled with different DTOs?

I'm using the TypeScript library "Automapper" in my NestJS backend to convert an answer of MongoDb/Mongoose to an DTO. That's how the answer looks like: { "

I can't call PATCH method using Pug, Mongoose and Express.js

I am new to code and I apologize in advance for all my noob mistakes. I'm trying to set a new color to an existing object stored in MongoDB using the PATCH meth

How to query mongoDB with mongoose without having a model

so i want to query my mongo DB without using a model, let me preface this by saying, i am looking for options other than using the mongodb driver. so in one app

MongooseError: Operation 'featureds.find()` buffering timed out after 10000ms

I have a collection on MongoDB from which I'm trying to query all the elements using find(): const mongoose = require('mongoose'); const Featured = mongoose.mod