No aggregations database

Hello, I’m correctly connected on Atlas with mongo, I do not see the expected database ‘aggregations’ to perform Lab work.
MongoDB Enterprise Cluster0-shard-0:PRIMARY>
MongoDB Enterprise Cluster0-shard-0:PRIMARY> show dbs
admin 0.000GB
local 3.539GB
MongoDB Enterprise Cluster0-shard-0:PRIMARY>

Do I miss a step ?

What is your connection URI?

I use the connection string given by Atlas:
mongo “mongodb://cluster0-shard-00-00-9a3rv.mongodb.net:27017,cluster0-shard-00-01-9a3rv.mongodb.net:27017,cluster0-shard-00-02-9a3rv.mongodb.net:27017/test?replicaSet=Cluster0-shard-0” --ssl --authenticationDatabase admin --username MyUserName --password MyPassword

I think that for M121 you should connect to the course cluster which has the URI:
mongodb://cluster0-shard-00-00-jxeqq.mongodb.net:27017,cluster0-shard-00-01-jxeqq.mongodb.
net:27017,cluster0-shard-00-02-jxeqq.mongodb.net:27017/aggregations?replicaSet=Cluster0-shard-0

and the username/password is m121/aggregations.

Just to make sure I don’t point you to the wrong direction, which lab are you trying to complete?

I’m on the M121 course.

Then, give it a try with the URI and credentials I mentionned. Note the URI must be on a single line, preferably within single quote. Cut-n-paste might introduce unwanted newlines and spaces.

Hey can someone please help me connect to Atlas. I am trying the following link in the mongo shell and it keep showing me the ’ SyntaxError: missing ; before statement @(shell):1:6’.

I know I am pretty late for this basic step.

The URI is argument of the mongo shell, not a command within the shell.

Then what to do with the command?

https://docs.mongodb.com/manual/mongo/

@

The connection is given in the Lecture notes

mongo “mongodb://cluster0-shard-00-00-jxeqq.mongodb.net:27017,cluster0-shard-00-01-jxeqq.mongodb.net:27017,cluster0-shard-00-02-jxeqq.mongodb.net:27017/aggregations?replicaSet=Cluster0-shard-0” --authenticationDatabase admin --ssl -u m121 -p aggregations --norc

Notice that this is all on one line – no carriage returns etc. You do not need a userid and password to access this. Good luck.

Hey I tried. But it is showing me the following error:
2019-01-14T23:38:42.190+0530 E QUERY [js] SyntaxError: missing ; before statement @(shell):1:6

Hey I read the doc. I am still not able to connect atlas with mongodb from mongodb shell.
It is constantly showing me the following error:
2019-01-14T23:38:42.190+0530 E QUERY [js] SyntaxError: missing ; before statement @(shell):1:6

@ adhish9899

The error message shows that you have an invalid character at line 1, character 6 in what you have put into the shell. (Very often, that’s a space or a line break, but I can’t tell here.) In any case, the connection string must be all on one line. HTH.

@ adhish9899

Also be sure that the quote marks shown are not “smart quotes” but simple quotes. HTH.

Thanks for the help @DHz.

I was not able to connect due some bin directory issue I have solved it now.