embedded system,Arduino,Raspberry pi,ARM7,MM32,STM32,PIC and Python,Django,Datascience and web development
Thursday, February 13, 2020
How to connect phpmyadmin mysql with python
import pymysql
conn=pymysql.connect(host="localhost",user="root",password="",db="my_python")
mycursor=conn.cursor()
mycursor.execute("""CREATE TABLE names
(id int primary key,
name varchar(20)
)
""")
conn.commit()
conn.close()
No comments:
Post a Comment