Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Oct 06 20:38

    nbbeeken on evergreen-integration

    (compare)

  • Oct 06 20:38

    nbbeeken on evergreen-integration

    (compare)

  • Oct 06 20:38

    nbbeeken on issue-template

    (compare)

  • Oct 06 20:38

    nbbeeken on issue-template

    (compare)

  • Oct 06 20:28
    durran added as member
  • Oct 06 20:28
    durran added as member
  • Oct 06 20:28
    kmahar added as member
  • Oct 06 20:28
    kmahar added as member
  • Oct 06 20:28
    nbbeeken added as member
  • Oct 06 20:28
    nbbeeken added as member
  • Oct 06 20:27
    dariakp added as member
  • Oct 06 20:27
    dariakp added as member
  • Oct 06 19:58

    nbbeeken on 2.0

    chore(release): 2.0.0-beta.0 (compare)

  • Oct 06 19:58

    nbbeeken on 2.0

    chore(release): 2.0.0-beta.0 (compare)

  • Oct 06 19:58

    nbbeeken on v2.0.0-beta.0

    (compare)

  • Oct 06 19:58

    nbbeeken on v2.0.0-beta.0

    (compare)

  • Oct 06 19:53

    nbbeeken on 2.0

    feat(NODE-3472)!: convert to No… (compare)

  • Oct 06 19:53

    nbbeeken on 2.0

    feat(NODE-3472)!: convert to No… (compare)

  • Oct 06 19:33

    nbbeeken on 2.0

    (compare)

  • Oct 06 19:33

    nbbeeken on 2.0

    (compare)

Azar
@azartheen
why these kinds of error happen in node js
TudorIoanMarin
@TudorIoanMarin

Hello guys. I was wondering, what is the approach to querying a collection with a dynamic field.
Let's say we have collection A { type, name, price } and a map of values B that holds the average price of a type of A, and can acces the value like so: B[A.type].avg.

What I want to do is create a dynamic query that will basically return the cheapest documents of a type but I can't figure out if this is doable in one query.

A.find({ price: { $lte: { B[A.type].avg } } })

I imagine there is an aggregate method fot this, can someone point me in the right dirrection?

Thanks

Nitendra Singh Yadav
@nitendra-yadav
can anybody help me in filling missing dates in array of orders with some default or null values
pedrospecter
@pedrospecter
Hej everybody
1 reply
quick question. Is it possible to have automated robots inside mongo so that they update some fields automatically?
Philip Lysenko
@philly-vanilly
What a useless chatroom. I scrolled 20 posts up, all were questions, no answers
Alan Levi
@Al2zone
noob question: have you ever seen this error? I'm having trouble connecting to a new db I created. "MongoParseError: Invalid source admin for mechanism MONGODB-X509 specified." I'm using the mongodb nodejs library to connect.
robin
@RobinYang11
image.png
image.png
robin
@RobinYang11
knick all your pp
pejman
@pejman-74
[http://mongodb.github.io/node-mongodb-native/3.1/api/ChangeStream.html ] according to this document next function must return null if no exist anymore document but for me not working .
Matthew
@ChaplainsBud
what's MongoDB Native?
is this React Native with MongoDB and Nodejs?
Daniel
@danjl23
What is the difference between using MongoDB Driver vs Mongoose?
Neil Duffy
@skiv71
@danjl23 Mongoose provides ORM, in the form of Models specific to the collection via Schemas (and object methods) to interact with mongo itself (like a wrapper)
the mongo driver lets you directly access the db itself
ehsan2003
@ehsan2003
Hi.
what is the best way to prevent duplicate data on mongodb?
I think there is two ways to do this:
1.we can check for existence of the duplicate data before inserting data
2.we can use unique indexes to do the job
I am trying to work with the second solution
but I have a problem with it because recently I can't receive keyPattern from mongoError object ( I am using keyPattern to determine which unique index triggered)
image.png
also the keys are not visible in messages
( I am using mongodb-memory-server for testing and this problem appears when testing )
Dane411
@Dane411
Hi, using mongodb@3.6.4 on node@14.15.0 I get the following error that comes from write_concerns.js:
Top-level use of w, wtimeout, j, and fsync is deprecated. Use writeConcern instead.
Any idea why I'm getting this warning and how to fix it?
What would be the recommended version of mongodb to downgrade and try to see if such warn dissapears?
Dhani A.
@_dhaniboy_twitter

Hi all, I have a collection that looks like this:

[
   { _id: 1,  color: "Blue,Green",  },
   { _id: 2,  color: "Blue", },
   { _id: 3,  color: "Green", }
]

color could be a string of comma separated values as in “Blue,Green” or a single string value as in “Blue”. 

Given a search string of “Blue”, I want to be able to return “Blue,Green” and “Blue”. Similarly, given a search string of “Green”, I want to be able to return “Blue,Green” and “Green”. I’m finding it hard to write such a query. Any ideas please?

I’m not using any ORM library . Mongo Version: 4.0.6.
Thanks

Neil Duffy
@skiv71
change color to "colors" to and an array, then https://docs.mongodb.com/manual/tutorial/query-arrays/
Dhani A.
@_dhaniboy_twitter
Thanks. Makes sense.
Neil Duffy
@skiv71
:thumbsup:
Furry
@Furry
Hiya! I'm starting a project that is very latency sensitive. The DB for this project won't be large, probably only around 100-150mb, does the NodeJS MongoDB driver allow me to keep this database mostly in memory, only writing to the cloud on occasion?
I don't want it spending time getting data from the cloud with every action..
I'm unsure if the driver does this by default
JeffWiebe
@JeffWiebe
Can anyone point me to more complete information on unified topology besides what is found in the MongoDB docs here: https://mongodb.github.io/node-mongodb-native/3.3/reference/unified-topology ?
Jay Patel
@jay0512
node package -> mongodb V 3.5.7
When I am trying to use aggregate lookup pipeline, I am getting the error 'MongoError: let not supported'
Can anyone elaborate why it is happening?
Kamil
@Chester97
Hi, I have simple question - how to make an aggregation on specific document?
Stas
@stasvo
Hello, is it ok to use unique string as _id instead of ObjectID, or I will have some problems if will use just unique string?
dpsh cudi
@dpz3579
Can someone help me with auto-encryption gist.
dpsh cudi
@dpz3579
is someone facing this warning
Warning: the options [credentials] is not supported
Trinh Dinh Bien
@bienkma
Hi guys,
Can we add/remove sharded to sharded cluster and no locking during processing? I need add/remove some sharded to currently sharded cluster. (mongodb 4.4.2 sharded cluster)
Trinh Dinh Bien
@bienkma

is someone facing this warning

Warning: the options [credentials] is not supported

change crypto authenticate method or client don't have essential crypto lib.

Divyansh Chaurasia
@Asdivyansh

Hello Everyone, 👋

I am hosting a workshop about- Building your first video conferencing app! :bulb:
Join us this Friday, as we will be building a video conferencing app from scratch in the workshop using JS. 🛠

:calendar: - July 9th, 2021
:alarm_clock: - 12.00 PM EST | 9.30 PM IST
Know more-
https://community.100ms.live/build-video-conferencing-app

P.S- We are also doing a surprise giveaway, sign up to know more!

Trinh Dinh Bien
@bienkma

Hi guys,
Can we add/remove sharded to sharded cluster and no locking during processing? I need add/remove some sharded to currently sharded cluster. (mongodb 4.4.2 sharded cluster)

I solved the problem. Basically, I used the method remove/add node to sharded cluster.

choudharyratnesh
@choudharyratnesh

Hi Guys, @tzhuan
I am facing a problem in running mogodb aggregate lookup function on object id of document
i have two document from different tables
Department Table document
{
"_id" : ObjectId("60b5d01d3cad3268ec30a4db"),
"designationId" : [
ObjectId("60b5d6483cad3268ec30a513")
],
"creationTime" : 1622525747967.0,
"isActive" : true,
"name" : "CT Dept One",
"organizationId" : ObjectId("60b5cf7d3cad3268ec30a4c7"),
"brandUserId" : ObjectId("60ae11608646230e9cea8ee9"),
"createdby" : ObjectId("60ae11608646230e9cea8ee9"),
"createdAt" : ISODate("2021-06-01T06:13:49.639Z"),
"updatedAt" : ISODate("2021-06-01T06:40:08.453Z"),
"v" : 1
}
Organization Table
{
"_id" : ObjectId("60b5cf7d3cad3268ec30a4c7"),
"creationTime" : 1622525747965.0,
"isActive" : true,
"name" : "CT PVT LTD",
"brandUserId" : ObjectId("60ae11608646230e9cea8ee9"),
"createdby" : ObjectId("60ae11608646230e9cea8ee9"),
"createdAt" : ISODate("2021-06-01T06:11:09.783Z"),
"updatedAt" : ISODate("2021-06-01T06:11:09.783Z"),
"
v" : 0
}

I have tried every solution return mention here
https://stackoverflow.com/questions/41093647/mongodb-join-on-id-field-from-string-to-objectid
to get data from Organization table in to department table.
please help me to solve this problem.

@bienkma please help me in this problem
Daniel Muriithi
@Dany20
Hello friends, I have a question on mongodb compass. I've created databases in my own computer and I would like another user to have access to these databases on his own computer. How do I go about it?
MERN Stack Boilerplate
@mernjs

Hello Everyone, MERN Stack Boilerplate provides starter kits for building web, desktop and mobile apps in pure JavaScript.

https://www.npmjs.com/package/create-mernjs-app

If you have any query or suggestions. Please let me know.

node.js.developers.kh
@nodejsdeveloperskh

I am working with node-mongodb-drive and i can not use $merge stage in the aggregate. mongodb throw this error: MongoError: Unrecognized pipeline stage name: '$merge'.

what can i do?

  • the same aggregate works in the mongo-compass.