Arrghh... I am trying to use mySQL with Python. I have installed all the libraries for using mySQL, but keep getting the: "ImportError: No module named mysql.connector" for "import mysql.connector", "mysql", etc..
Here is my config:
I have a RHEL server:
Red Hat Enterprise Linux Server release 6.7 (Santiago)
with Python 2.7.9
Python 2.7.9 (default, Dec 16 2014, 10:42:10) [GCC 4.4.7 20120313 (Red Hat 4.4.7-11)] on linux2
with mySQL 5.1
mysql Ver 14.14 Distrib 5.1.73, for redhat-linux-gnu (x86_64) using readline 5.1
I have all the appropriate libraries/modules installed, I think!
yum install MySQL-python
Package MySQL-python-1.2.3-0.3.c1.1.el6.x86_64 already installed and latest version
yum install mysql-connector-python.noarch
Installed: mysql-connector-python.noarch 0:1.1.6-1.el6
yum install MySQL-python.x86_64 Package MySQL-python-1.2.3-0.3.c1.1.el6.x86_64 already installed and latest version
yum install mysql-connector-python.noarch
Package mysql-connector-python-1.1.6-1.el6.noarch already installed and latest version
What am I doing wrong? HELP!?
Virtual Enviroment
docs.python-guide.org/en/latest/dev/virtualenvs If not you are running the risk of having an unorganized system, your environment may not be looking in the right place for your python modules – DanHabibimport MySQLdb
– Vor