mirror of
https://bitbucket.org/SosoM1k0r31z31/funny-cat.git
synced 2025-04-11 22:55:46 +02:00
1
database
SosoM1k0r31z31 edited this page 2020-11-13 12:47:45 +00:00
To self host this bot, you must first create an SQlite database.
To do so, first import these python modules
#!python
import sqlite3
from sqlite3 import Error
After that, you can use the following code to create the actual databse.
#!python
with connection:
connection.execute("""
CREATE TABLE TAG (
id INTEGER,
name TEXT not null,
content TEXT not null,
date INTEGER,
unique (name)
);
""")