From 977447e72c53a718e83e260b6e85e7ea59355a64 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Krzysztof=20Le=C5=9Bniak?= <klesniak@syncad.com>
Date: Wed, 29 Jan 2025 14:40:20 +0100
Subject: [PATCH] Don't use hive_rowid in
 hivemind_app.hive_raw_notifications_as_view

---
 hive/db/sql_scripts/notifications_view.sql | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hive/db/sql_scripts/notifications_view.sql b/hive/db/sql_scripts/notifications_view.sql
index 31835ac3d..5c75d759e 100644
--- a/hive/db/sql_scripts/notifications_view.sql
+++ b/hive/db/sql_scripts/notifications_view.sql
@@ -118,7 +118,7 @@ CREATE OR REPLACE VIEW hivemind_app.hive_raw_notifications_as_view
                                     WHERE m.follower = hpv.parent_author_id AND m.following = hpv.author_id)
 UNION ALL
  SELECT f.block_num,
-    hivemind_app.notification_id(f.block_num, 15, f.hive_rowid::integer) AS id,
+    hivemind_app.notification_id(f.block_num, 15, (row_number() OVER ())::INTEGER) AS id,
     0 AS post_id,
     15 AS type_id,
     (select hb.created_at from hivemind_app.blocks_view hb where hb.num = (f.block_num - 1)) as created_at, -- use time of previous block to match head_block_time behavior at given block
-- 
GitLab