Category "mongodb"

Insert data with new fields OR update conditionally using updateOne mongodb

I have a document with format like this: { "f1": "v1", "f2": { "id": 1, "sub": "subv", "updatedAt": 123 } } I have an another source that

Add older documents to stream - based on filter

I created a MongoDB watcher to create actions based on the created document. Of course, the watcher does not detect documents that are created while the service

WebFlux Spring Boot @Transactional with reactive MongoDB

Does WebFlux Spring Boot @Transactional annotation work with reactive MongoDB? I use WebFlux Spring Boot with reactive MongoDB like: id 'org.springframework

Update array object mongoDB

I have an array of objects and would like to update the count of the object where categoryId = "menu2" and subCategoryId = "1". in my mongodb i currently have t

how to sum 2 numbers in javascript before saving it in mongodb database

I'm building a web app using MERN stack. I want to sum 2 numbers then save it mongodb database. Here current num is from database and other is from input field

Update array object mongoDB

I have an array of objects and would like to update the count of the object where categoryId = "menu2" and subCategoryId = "1". in my mongodb i currently have t

How to update ISODate to two days later

How to convert a SQL query to mongodb query? Please write a mongodb query - this is my query in SQL: UPDATE user SET expireIn = DATEADD(DAY, 2, expireIn) WHE

How to create Database wallet into hyperledger-fabric?

I need to use a database (mysql/mongodb) instead of files to store the user's wallet identity into hyperledger-fabric.

Set a new field based on calculations in MongoDB update statement

I use the attribute pattern approach in my collection: [ { _id: "id1", _cells: [ { k: "key1", v: "value1" }, { k: "key2", v: "value2" },

Use limit and skip in MongoRepository<Customer,String>

We are working on a project to get data from mongoDB. We have created repository class as below @Repository public interface CustomerRepository extends MongoRep

pythonanywhere is not updating mongoDB

@app.route('/signup', methods=['POST']) def signup(): info = request.args if info["password"] == info["password2"] and info["name"] and info["email"] an

undefined method `map' for #<ActionController::Parameters Rails 6.0

Getting this error when trying to call the method validate_create_action. The error occurs on the line @element = klass.new(params[:element]

How to return all types except a certain type in MongoDB?

Let's say that there is a column called colours and it can have values red, blue, and green. I want to retrieve all rows except the ones where the colour is gre

Mongodb aggregate group by then conditional sum, or, filter, push, using c#

Can someone please help to convert this query to C# .NET core? db.getCollection("accout").aggregate().match({ $or: [{"clientnum1": "xxxx"},{ "clientnum2": ""}],

Spring boot mongodb QuerydslPredicateExecutor ClassNotFoundException: com.querydsl.mongodb.document.MongodbDocumentSerializer

I'm trying to use QuerydslPredicateExecutor. Here is my repository interface: public interface ProductsRepository extends MongoRepository<Product, String

MongoDB get sum of fields which I have modified in the project pipeline

I want to calculate avgAmount as the sum 3 fields = [balanceLoaded + operatorDueAmount - walletUsage]. But these fields can either be zero or themselves (balanc

Mongoose Schema for Groups (a number of users in one group)

One aspect of my website is that people can join groups according to a specific code provided to them, for example- when we play 'Kahoot' or 'Psych', we have to

Incrementing a "PlayerID" with a MongoDB Atlas Trigger

I need to have a playerID that is separate from _id and increments with each new entry into my users collection. I have tried to follow this tutorial with no lu

I have trying to update my quantity in mongodb server Its showing Null. How Can I solve this?

##I have trying to update my quantity in mongodb server Its showing Null. How Can I solve this?## ``` const handleSubmit = event =>{ const inputQuantity

Why I am getting "Not Implemented Error: Database objects do not implement truth value testing or bool()." while running makemigration cmd in django

I am trying to connect Django with MongoDB using Djongo. I have changed the Database parameter but I am getting this error Not Implemented Error: Database objec