This article describes how to install sqlalchemy in python in windows and how to prepare tools before installing sqlalchemy. For more information, see
For windows operating systems, install easy_install first.
. Install setuptools (easy_install ):
A. For a 32-bit windows Operating System
For a 32-bit windows operating system, find the corresponding exe and install it.
B. For a 64-bit windows Operating System
If windows 64 does not have an installation package, you must compile and install the package as follows:
Download ez_setup.py
Run:
The Code is as follows: |
Copy code |
Python ez_setup.py
|
2. Configure the environment variable:
For example, the path to my computer is D: toolsPython27Scripts.
Add to Environment Variable
-- EOF --
After easy_install is installed successfully, we will install sqlalchemy for python.
Then execute the following command
The Code is as follows: |
Copy code |
Easy_install SQLAlchemy |
The installation is successful as follows:
The Code is as follows: |
Copy code |
D:> easy_install SQLAlchemy Searching for SQLAlchemy Reading http://pypi.python.org/simple/SQLAlchemy/ Reading http://www.sqlalchemy.org Best match: SQLAlchemy 0.8.0b2 Downloading http://pypi.python.org/packages/source/S/SQLAlchemy/SQLAlchemy-0.8.0 B2.tar.gz # md5 = 09537c7bda-d0be433f7aceabbf23d68 Processing SQLAlchemy-0.8.0b2.tar.gz Running SQLAlchemy-0.8.0b2setup.py-q bdist_egg -- dist-dir c: usersw3appdata Localtempeasy_install-lnagt1SQLAlchemy-0.8.0b2egg-dist-tmp-0flwk1 Warning: no files found matching '*. jpg 'under directory 'Doc' No previusly-included directories found matching 'docbuildoutput' **************************************** *********************************** Unable to find vcvarsall. bat WARNING: The C extension cocould not be compiled, speedups are not enabled. Failure information, if any, is abve. Retrying the build without the C extension now. **************************************** *********************************** Warning: no files found matching '*. jpg 'under directory 'Doc' No previusly-included directories found matching 'docbuildoutput' Zip_safe flag not set; analyzing archive contents... **************************************** *********************************** WARNING: The C extension cocould not be compiled, speedups are not enabled. Plain-Python build succeeded. **************************************** *********************************** Adding sqlalchemy 0.8.0b2 to easy-install.pth file Installed d: toolspython27libsite-packagessqlalchemy-0.8.0b2-py2.7.egg Processing dependencies for SQLAlchemy Finished processing dependencies for SQLAlchemy |
D:>
-- EOF --