From 59f404883e373be696f70bd3655fe14efbea2fa6 Mon Sep 17 00:00:00 2001 From: SoXX Date: Tue, 15 Oct 2024 12:28:52 +0200 Subject: [PATCH] fix(database): migration - primary key is now first in position --- pkg/database/migrations/004_scrape_history.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/database/migrations/004_scrape_history.sql b/pkg/database/migrations/004_scrape_history.sql index 5d23e44..5ae010b 100644 --- a/pkg/database/migrations/004_scrape_history.sql +++ b/pkg/database/migrations/004_scrape_history.sql @@ -1,8 +1,8 @@ -- +migrate Up CREATE TABLE "ScrapeHistory" ( - user_source_id CHAR(25) NOT NULL REFERENCES "UserSource" (id), scrape_task_id CHAR(25) PRIMARY KEY, + user_source_id CHAR(25) NOT NULL REFERENCES "UserSource" (id), created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, finished_at TIMESTAMP NULL, error TEXT NULL,