feat:some_improvement

This commit is contained in:
Оля Мороз
2026-10-07 17:33:29 +03:00
parent 828a9f792a
commit 9773639f52
17 changed files with 620 additions and 23 deletions
+13
View File
@@ -0,0 +1,13 @@
-- Сверка: count + контрольные сообщения.
SELECT 'src' AS side, count(*) AS messages FROM messages
UNION ALL
SELECT 'restore', count(*) FROM dblink(
'dbname=messenger_restore user=messenger',
'SELECT count(*) FROM messages'
) AS t(n bigint);
-- Контрольные UUID: 5 самых старых сообщений.
SELECT id, chat_id, sender_id, text, created_at
FROM messages
ORDER BY created_at, id
LIMIT 5;