본문 바로가기

학원/Python

MySQL 연결

[ 목차 ]

1. My SQL 설치

2. 파이참에서 PyMySQL 모듈 설치

3. 연결

4. 쿼리 실행

5. 종료

6. select와 insert

 

1. My SQL 설치

https://www.mysql.com/downloads/

 

MySQL :: MySQL Downloads

Contact MySQL  |  Login  |  Register The world's most popular open source database MySQL.com Downloads Documentation Developer Zone MySQL Enterprise Edition includes the most comprehensive set of advanced features and management tools for MySQL. MySQL

www.mysql.com

 

2. 파이참에서 PyMySQL 모듈 설치

1) 터미널 실행

2) pip PyMySQL 입력

3) 터미널에 pip list 입력하여 설치 확인, 또는 settings에서 확인 가능

 

3. 연결

1) import 후 db연결하기

 

4. 쿼리 실행

 

5. 종료

 

6. select와 insert

'학원 > Python' 카테고리의 다른 글

MsSQL 연결  (0) 2020.05.28
Sqlite 사용  (0) 2020.05.28
8. 파이썬 기본문법8  (0) 2020.05.26
7. 파이썬 기본문법7  (0) 2020.05.25
6. 파이썬 기본문법6  (0) 2020.05.22