问题
I installed Python 3.6.5 on Windows 10. I see that there is a sqlite3 folder in ...\Python\Python36\Lib directory. I added Python PATH to environment variable. However, I can't run the command "sqlite3" from Powershell nor Git Bash. It would say "command not found". What did I do wrong?
回答1:
Python's sqlite library probably is installed. Try: import sqlite3
in the Python shell.
If you want to be able to use sqlite's CLI program, you need to install it.
Download here. Use the Windows version obviously.
回答2:
Check the permissions of the folder where python3 is installed, it may be that when using powershell you do not have the necessary permissions to access them.
It is always highly recommended to install python3 in a route WITHOUT SPACES
like a:
C:\python36
回答3:
So, apparently Sqlite3's CLI does not come installed with Python (Python 3.6). What comes pre-installed is Python's Sqlite3 library.So, you can access the Sqlite3 DB either through the library, or by manually installing Sqlite3 CLI.
来源:https://stackoverflow.com/questions/50205804/sqlite3-command-not-found-python-3-on-windows-10