Install PyMongo, the Python Driver; Connect to MongoDB; Explore MongoDB Collections and Documents; Perform basic Create, Retrieve, Update and Delete (CRUD) operations using PyMongo; Let's get started! You can start working immediately with MongoDB by using a free MongoDB cluster via MongoDB Atlas.
- Install Pymongo Anaconda
- Install Pymongo
- Install Mongodb Terminal
- Install Pymongo For Python 2.7
- Install Pymongo For All All User In Ubunt
- Pymongo Client
Active5 months ago
- Hellow everyone, i tried to install PyMongo package with pip( i hope that is the way to do it). [its a part of a login system] my command line was.
- Installing / Upgrading¶ PyMongo is in the Python Package Index. Do not install the “bson” package. PyMongo comes with its own bson package; doing “pip install bson” or “easy_install bson” installs a third-party package that is incompatible with PyMongo. To install PyMongo on these systems with C extensions you may need.
I am currently trying to install MongoDB driver for Python on my Mac OS X (mavericks).
But when I run
I get the following output
I try a lot of different commands, but nothing work. How to install pymongo ?
Thanks for your help
Edit: When I try to use it in a python script
I have this error
Markus W Mahlberg13.8k55 gold badges4444 silver badges6565 bronze badges
Anthony PradalAnthony Pradal
10 Answers
JayramJayram11.9k66 gold badges4242 silver badges6464 bronze badges
I have same error , and I can fix it following command.
Try this. but this command for Ubuntu 14.04 OX.not sure is this work in Max OS X.
umauma71811 gold badge1414 silver badges3636 bronze badges
Installing pymongo goes very simple
![Mongodb Mongodb](/uploads/1/3/3/2/133272430/925619072.jpg)
Make sure that python is installed already in your machine.If not check here for quick installation.
CentOS:
Update using yum
Download the pip using curl:
Install pip command using python
Install pymongo using pip
JERRYJERRY5,16511 gold badge1717 silver badges3131 bronze badges
Jonathan BencomoJonathan Bencomo
you can use these commands
To get a specific version of pymongo:
To upgrade using pip:
To use easy_install from setuptools do:
To upgrade do:
Ash UpadhyayAsh Upadhyay
Install Pymongo Anaconda
I think you can download the .egg file here and install with
Rob♦23.3k1212 gold badges6161 silver badges8080 bronze badges
despereaux guandespereaux guan
On Ubuntu 18.04,
For this, the version of the pip should be less than or the same as 9.0.1.
First of all, install the pip for python version 3 from-
and check pip version-
Install Pymongo
after that, we have to install build-essential for python-dev
and python setup-tools
And finally, we are able to install pymongo by following command-
It worked for me, may it will work for you too.
Arun KumarArun Kumar
Don Brody76811 gold badge88 silver badges2222 bronze badges
SyedSyed
Yogesh Nikam PatilYogesh Nikam Patil
I'm running python 2.7.12 on Rasbian Jesse. After running:
The following command reveals that the pymongo module exists under /usr/local/lib/python2.7/dist-packages/
Install Mongodb Terminal
One methods that works is to append the sys path with the location of the pymongo module:
D1v3D1v3
Not the answer you're looking for? Browse other questions tagged pythonpymongo or ask your own question.
Active6 months ago
hellow everyone,i tried to install PyMongo package with pip( i hope that is the way to do it). [its a part of a login system]
my command line was:
But, when i put it in the command line i got
Install Pymongo For Python 2.7
And the import line in the code was:
Do someone knows what should i do?Thanks!!
user9678733
2 Answers
Flask-PyMongo is a different package than PyMongo. It looks like you've only installed PyMongo, but are trying to use Flask-PyMongo in your application. You should run
dcrostadcrostaC:/Python36/Scripts/pip install Flask-PyMongo
to install Flask-PyMongo.20.1k77 gold badges6060 silver badges7979 bronze badges
You installed PyMongo and tried to import PyMongo from
flask_pymongo
.Install Pymongo For All All User In Ubunt
PyMongo is a package to work with MongoDB. To make this work more efficient, Flask just made an extension named 'Flask-PyMongo'. So, we can directly import 'Flask-PyMongo' and start working with MongoDB in a very efficient way.
You can think 'Flask-PyMongo' as a wrapper of 'PyMongo'.
grooveplex1,59544 gold badges1717 silver badges2626 bronze badges
Pymongo Client
AqurdsAqurds