codepad
[
create a new paste
]
login
|
about
Language:
C
C++
D
Haskell
Lua
OCaml
PHP
Perl
Plain Text
Python
Ruby
Scheme
Tcl
import sqlite3 db = sqlite3.connect("data.sqlite") cursor = db.cursor() cursor.execute("CREATE TABLE table IF NOT EXISTS(author INT, channel INT)") cursor.execute("INSERT INTO table (author, channel) VALUES(0, 1)") cursor.execute("INSERT INTO table (author, channel) VALUES(1, 2)") print(cursor.execute("SELECT * FROM table").fetchall())
Private
[
?
]
Run code
Submit