K
K
KOTshredingera1232022-03-25 16:28:53
Arrays
KOTshredingera123, 2022-03-25 16:28:53

Creating, iterating and comparing an array with a database?

The point is, there is a list of emails, they need to be sorted through the database and these emails can be found, but only those that have a password field. You need to somehow make an array from the list of emails, and then brute force compare them with the database and find only those who have emails.
Db.getCollection("users").find(
{
"email" : "here you need to sort through
the list of emails",
"password" : {
"$exists" : true
}
}
);

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question