#12 - update feeds

This commit is contained in:
2025-03-11 15:25:52 +02:00
parent a76915c7fc
commit f561eb4c34
10 changed files with 131 additions and 22 deletions

View File

@@ -0,0 +1,2 @@
-- name: GetNextFeedToFetch :one
SELECT * FROM feeds ORDER BY last_fetched_at NULLS FIRST LIMIT 1;

View File

@@ -0,0 +1,3 @@
-- name: MarkFeedFetched :one
UPDATE feeds SET last_fetched_at = CURRENT_TIMESTAMP, updated_at = CURRENT_TIMESTAMP WHERE id = $1
RETURNING *;