Questions tagged [nosql-aggregation]

Questions related to Aggregation functions in NoSQL databases.

Questions related to Aggregation functions such as Count() or Sum() in NoSQL databases.

313 questions
0
votes
1 answer

NoSQL Database Design for FSA

I need to design a NoSQL database for a system that is using an FSA(Fare Service Aggregator) which is having a very heavy load including major scenarios, database aggregates, and queries. Are any references on how to design a NoSQL database of…
0
votes
1 answer

How to properly unwind my array in mongodb

I need to unwind my prescriptions so I can get the total count per prescription Here is one of my inserts { "_id" : 1, "patient" : { "name" : "Locke, John", "id": 1, "sex": "male", "age": 52 }, …
0
votes
1 answer

Looking for function similar to "BETWEEN" in MongoDB

I need to get all records from MongoDB collection "employee" where joining_date is between current_date and current_date + 5 days. I couldn't find anything similar to BETWEEN operator in MongoDB documentation. Below query works fine in Google…
0
votes
1 answer

How to find the count of the number of documents in mongodb using pymongo aggregation?

I'm trying to find the max value of a field from a number of documents and want the output to not only reflect the max value of the field but also the total count of documents that the aggregate query will retrieve. I'm able to retrieve the "wait"…
JUAmaned
  • 49
  • 1
  • 5
0
votes
1 answer

is there and MongoDB GUI tool where we can create Aggregation queries online

I have seen NoSQLBooster but this only supports "find" function in its visual query builder. Is there and mongodb tool where we can use aggregation pipeline functions and functions like "set" "findandmodify" visually ? eventually i want to…
Raas Masood
  • 1,475
  • 3
  • 23
  • 61
0
votes
1 answer

Finding the mongoDB object

I have a Sequence : [k1,k4,k6,k10]and a MongoDB object as follows:{"_id" : "x" , "k" : [ "k1", "k2 ","k6"]},{"_id" : "y" , "k" : [ "k2", "k4 ","k10","k11"]},{"_id" : "z" , "k" : [ "k4", "k6 ","k10","k12"]} I have to find the particular object which…
zolo
  • 7
  • 4
0
votes
1 answer

Can you update a collection in MongoDB and remove the first/last char on one field?

My question might be simple be here's some more context to it. I have a MySQL DB, I've used an ETL tool to populate a MongoDBwith, however I couldn't manage to create proper ObjectId reference to it (I can only get a string of the ObjectId. So far…
0
votes
1 answer

Nested entry in mongodb, sum and average only over max of a subfield

I have a db which contains documents, i.e.: { id: "first_document", document: [ {page: 1, content: "text"}, {page: 2, content: "text"}, {page: 3, content: "text"}]}, { id: "second_document", document: [ {page: 1, content: "text"}, {page: 2,…
FMarazzi
  • 583
  • 1
  • 5
  • 14
0
votes
0 answers

List available fields in a MongoDB database

MongoDB is a Schemaless, NoSQL database. But for simplicity and ease of use, users will use some form of schema to have some understanding of their data and simplify their use of database. Is/are there any methods with which one can list available…
Faiz Lotfy
  • 121
  • 1
  • 11
0
votes
1 answer

How to count size of sub-sub internal list in mongodb?

I'm new to MongoDB. I don't know much MongoDB queries. One query which I'm unable to find. "Get all students list and count of addressList". Document: { _id: 123, students: [ { studentId:987, studentName:"####", …
0
votes
1 answer

Mongodb complex script involving multiple collections

I'm new to mongodb and I was asked to complete a task: Some information: The mongodb version that is being used is 3.4.9. The script needs to be done using mongo shell. I have two collections - 'A' and 'B' I want to update a field in the 'A'…
0
votes
0 answers

find returns the required data but $match doesn't in mongodb

I am trying to get required data using $match but it is returning null every time. On the other hand find returns the required data. I have to implement $lookup and $merge on the result I get but $match results null. I have tried using a basic query…
0
votes
1 answer

Cloudant distinct operator

I am new to cloud-ant, In my current assignment i want to search all distinct records based on fields x: I have documents which have domain as attribute. I want all unique domains which are present in my db.Below is the…
0
votes
1 answer

MongoDB group by count based on condition

I have the below mongo DB schema: { "_id" : "5b76c3c037548390fdb5b40e", "userId" : "4601", "modified" : ISODate("2018-08-21T19:13:43.301+05:30"), "rStatus" : "started", }, { "_id" : "5b76c3c037548390fdb5b40e", "userId" :…
Sujeet Kumar
  • 1,280
  • 1
  • 17
  • 25
0
votes
1 answer

Multiple Grouping in NoSQL

I'm developing a Billing Software for maintaining daily records. I'm using PyGTk(for UI) and MongoDB(NoSQL) database. I'm storing record of each bill in following format { "_id" : ObjectId("5b83f95a3859201d46385779"), "date" : "27/08/2018", …
Abhishek
  • 23
  • 4