-
Notifications
You must be signed in to change notification settings - Fork 0
/
database_Creator.py
49 lines (38 loc) · 1.59 KB
/
database_Creator.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
import sqlite3
bot_Database = sqlite3.connect("bot_Database.db")
database_Cursor = bot_Database.cursor()
database_Cursor.execute("""CREATE TABLE bot_Users
(telegram_ID TEXT,
user_Unique_ID TEXT,
language_Select TEXT,
bot_Version REAL,
user_Position TEXT,
reg_Timestamp INTEGER)
""")
database_Cursor.execute("""CREATE TABLE spotify_Users
(user_Unique_ID TEXT,
user_Spotify_ID TEXT,
user_Nickname TEXT,
spotify_Code TEXT,
spotify_Auth_Token TEXT,
spotify_Refresh_Token TEXT,
auth_Timestamp INTEGER,
refresh_Timestamp INTEGER)
""")
database_Cursor.execute("""CREATE TABLE users_TopTracks
(user_Unique_ID TEXT,
short_term TEXT,
medium_term TEXT,
long_term TEXT)
""")
database_Cursor.execute("""CREATE TABLE users_TopArtists
(user_Unique_ID TEXT,
short_term TEXT,
medium_term TEXT,
long_term TEXT)
""")
database_Cursor.execute("""CREATE TABLE users_BlockedTracks
(user_Unique_ID TEXT,
blocked_Data TEXT)
""")
bot_Database.commit()