Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import mysql.connector
- banco = mysql.connector.connect(
- host="localhost",
- user="root",
- passwd="StrongPass",
- database="eX" #call a database for conter the table
- )
- mycursor = banco.cursor() #using cursor function to manage SQL for 'banco'
- mycursor.execute("CREATE TABLE students (name VARCHAR(255),age INTEGER(10))")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement