M201 Install Course Tools and dataset

Hi! I was able to create a new cluster via Atlas, create the DB and import the data. I can also see the DB via compass. I do not have mongodb installed locally, so how to I run the given commands?

use m201
db.people.count({ “email” : {"$exists": 1} })

Can this whole course be done via Atlas/Compass? Or do I need to run mongodb locally somehow?


To do

you select m201 like you did in your screenshot. But you also select People rather than Restaurants. In the text field with the label FILTER that is prefilled with { field : value } you type your query which is the part between the parenthesis, that is:

{ "email" : { "$exists" : 1 } }
1 Like

I am using localhost and I really need help importing data into the mongosh. I keep getting “Syntax Error: missing semicolon…” exception.

@Emeka_Udogadi can you please open a new post and add what commands/files you are trying to use.

You may be running mongoimport while connected to mongodb
Please exit and run it from os prompt($,# etc)
Also share the command as Yilmaz_Durmaz requested