aboutsummaryrefslogtreecommitdiffstats
path: root/schema.sql
diff options
context:
space:
mode:
authorPinapelz <yukais@pinapelz.com>2025-10-01 23:43:22 -0700
committerPinapelz <yukais@pinapelz.com>2025-10-02 01:27:15 -0700
commitc69189dbf844842049ca8a511803da89b5d1d9e9 (patch)
tree88784ff3d0f09ef9dfdbf94c919fd25f93ea4f99 /schema.sql
parent63dd4995224db0540be1bca7a8f8d463483f8e43 (diff)
add news feed archival to db
Diffstat (limited to 'schema.sql')
-rw-r--r--schema.sql7
1 files changed, 3 insertions, 4 deletions
diff --git a/schema.sql b/schema.sql
index 5c2e2f0..88e1120 100644
--- a/schema.sql
+++ b/schema.sql
@@ -1,5 +1,5 @@
CREATE TABLE IF NOT EXISTS news (
- id INTEGER PRIMARY KEY AUTOINCREMENT,
+ news_id VARCHAR(255) NOT NULL PRIMARY KEY,
date TEXT NOT NULL,
identifier TEXT NOT NULL,
type TEXT,
@@ -13,11 +13,10 @@ CREATE TABLE IF NOT EXISTS news (
);
CREATE TABLE IF NOT EXISTS news_images (
- id INTEGER PRIMARY KEY AUTOINCREMENT,
- news_id INTEGER NOT NULL,
+ news_id VARCHAR(255) NOT NULL PRIMARY KEY,
image_url TEXT NOT NULL,
link_url TEXT,
- FOREIGN KEY (news_id) REFERENCES news(id) ON DELETE CASCADE
+ FOREIGN KEY (news_id) REFERENCES news(news_id) ON DELETE CASCADE
);
CREATE TABLE IF NOT EXISTS summarization (
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage