在控制台中输入pip install pymysql即可,以下是输出:
C:Usershorn1Desktoppython15>pip install pymysql Collecting pymysql Downloading PyMySQL-0.8.0-py2.py3-none-any.whl (83kB) 100% |████████████████████████████████| 92kB 226kB/s Installing collected packages: pymysql Successfully installed pymysql-0.8.0 You are using pip version 9.0.1, however version 9.0.3 is available. You should consider upgrading via the 'python -m pip install --upgrade pip' command.