Skip to content

Instantly share code, notes, and snippets.

View LunarWatcher's full-sized avatar
🏳️‍⚧️
she/her

Olivia (Zoe) LunarWatcher

🏳️‍⚧️
she/her
View GitHub Profile
@LunarWatcher
LunarWatcher / com2sql.py
Created May 19, 2022 17:39
Converts the comment data dump from Stack Overflow to SQLite
import sqlite3 as sl3
import re
con = sl3.connect("comments.db")
cur = con.cursor()
cur.execute("""CREATE TABLE IF NOT EXISTS Comments (UserID INTEGER, CommentID INTEGER PRIMARY KEY, Content TEXT, PostID INTEGER)""")
con.commit()