This commit is contained in:
Moritz Riese
2024-12-29 01:20:01 +01:00
parent 90341b277c
commit 182ce5af6b
12 changed files with 276 additions and 31 deletions

View File

@@ -0,0 +1,8 @@
CREATE TABLE `users_table` (
`id` integer PRIMARY KEY AUTOINCREMENT NOT NULL,
`name` text NOT NULL,
`discord_id` integer NOT NULL,
`took_medication_today` integer DEFAULT 0 NOT NULL
);
--> statement-breakpoint
CREATE UNIQUE INDEX `users_table_discord_id_unique` ON `users_table` (`discord_id`);

View File

@@ -0,0 +1,65 @@
{
"version": "6",
"dialect": "sqlite",
"id": "ddb7170b-7f66-4e3c-ab64-9069e760e09a",
"prevId": "00000000-0000-0000-0000-000000000000",
"tables": {
"users_table": {
"name": "users_table",
"columns": {
"id": {
"name": "id",
"type": "integer",
"primaryKey": true,
"notNull": true,
"autoincrement": true
},
"name": {
"name": "name",
"type": "text",
"primaryKey": false,
"notNull": true,
"autoincrement": false
},
"discord_id": {
"name": "discord_id",
"type": "integer",
"primaryKey": false,
"notNull": true,
"autoincrement": false
},
"took_medication_today": {
"name": "took_medication_today",
"type": "integer",
"primaryKey": false,
"notNull": true,
"autoincrement": false,
"default": 0
}
},
"indexes": {
"users_table_discord_id_unique": {
"name": "users_table_discord_id_unique",
"columns": [
"discord_id"
],
"isUnique": true
}
},
"foreignKeys": {},
"compositePrimaryKeys": {},
"uniqueConstraints": {},
"checkConstraints": {}
}
},
"views": {},
"enums": {},
"_meta": {
"schemas": {},
"tables": {},
"columns": {}
},
"internal": {
"indexes": {}
}
}

View File

@@ -0,0 +1,13 @@
{
"version": "7",
"dialect": "sqlite",
"entries": [
{
"idx": 0,
"version": "6",
"when": 1735431085265,
"tag": "0000_needy_nightshade",
"breakpoints": true
}
]
}