i run this command pip3 install mysql-connector in Command Prompt and its show this:
C:\Users\pc>pip3 install mysql-connector Requirement already satisfied: mysql-connector in c:\users\pc\appdata\local\prog rams\python\python38\lib\site-packages (2.2.9).
but i still get ModuleNotFoundError: No module named 'mysql' when i import mysql.connector in spyder and pycahrm.
CodePudding user response:
In Spyder go to Tools > Preferences > Python interpreter, select Use the following Python interpreter: and choose the Python .exe from your other installation.
There is probably a similar setting in Pycharm’s preferences.
