I am creating a simple program using python 3.6. I want to connect to the MySQL to use it as my database. Unfortunately most of what i searched is connecting MySQL to lower versions of python. I cannot see about 3.6. Can someone guide me?
Asked
Active
Viewed 2,336 times
0
-
In what way? Do you need help with a specific technical aspect? Do you need literacy training so you can better understand the documentation? – Robert Columbia Oct 10 '17 at 17:23
-
I have used `mysqlclient` version 1.3.12 with `Python 3.6.2` in windows. See the provided answer of @FELASNIPER for `mysqlclient`. – arshovon Oct 10 '17 at 17:29
-
@RobertColumbia nope. I just cannot find any tutorials on using mysql in python. I mean getting started with it. But luckily i saw mysqlclient. I'm now good. Thanks! – Jaypee Oct 10 '17 at 17:37
-
@arsho yeah i saw it. Thanks! – Jaypee Oct 10 '17 at 17:37
2 Answers
1
mysqlclient
officially supports python3.6:
https://pypi.python.org/pypi/mysqlclient
Also read their documentation: https://github.com/PyMySQL/mysqlclient-python/blob/master/README.md

FELASNIPER
- 327
- 2
- 9
0
@Yaypee The following answer helped me: [caching sha2 password is not supported mysql
The question posted above is not the same as yours, but the answer tells you that you can use MySQL.connector
in python3.6. I installed it today using pip3.6 install MySQL-connector-python
on a Windows 10 machine. The package also supports sha256 cryptography which meant in my case that I could connect using a different user other than root. The latter of course is unrelated to your question.

Hmerman6006
- 1,622
- 1
- 20
- 45