I’m new to MongoDB and programming overall. I’m trying to return information about the MongoDB server by following the guide from this webpage PyMongo Tutorial: MongoDB And Python | MongoDB . After running my py. file (below a screenshot attached), I get errors -
mongodb+srv://user:password@cluster.mongodb.net/dbname?retryWrites=true&w=majority - that is my connection string and I wanted to clarify what what password I have to put in. I assume the one that I generated from database user, right?:
Correct me if I put the wrong data in my connection string and please advise why the code im running doesn’t provide the outcome as from the webpage link…
Apart from this mistake I used password from my account instead of using a password associated to a user database. I also used for a user database password the same password that I use for my account, which apparently is a bad practise, so I generated a new user database password and finally everything worked…
thanks