Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import psycopg2
- class utenti:
- def registra(self, email, nickname, passwrd):
- conn = psycopg2.connect("dbname='FANTAGOL' user='tonyfrancis' host='localhost' password='marianeri'")
- cur = conn.cursor()
- cur.execute("INSERT INTO Giocatori (email, nickname, passwrd) VALUES (%s, %s, %s)", (email, nickname, passwrd))
- conn.commit()
- cur.close()
- conn.close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement