repl.it
@Wilmor21/

mongo

Python

No description

fork
loading
Files
  • main.py
  • database.db
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import sqlite3

conn = sqlite3.connect("database.db")

c = conn.cursor() 

try:
	c.execute("""CREATE TABLE users (
				email,
				psw
		)""")
except:
	pass

c.execute("INSERT INTO users VALUES ('a','a')")

conn.commit()

c.execute("SELECT * FROM users WHERE psw='a'")

print(c.fetchall())

conn.close()