From c8487940bfd0e796e7fd572e543fe2cf88e191b1 Mon Sep 17 00:00:00 2001
From: Vitaly Takmazov
Date: Wed, 15 Aug 2018 00:02:13 +0300
Subject: Migrate telegram_chats to telegram table

---
 .../src/main/resources/db/migration/V1.2__Drop telegram_chats.sql       | 2 ++
 1 file changed, 2 insertions(+)
 create mode 100644 juick-server/src/main/resources/db/migration/V1.2__Drop telegram_chats.sql

(limited to 'juick-server/src/main/resources/db/migration/V1.2__Drop telegram_chats.sql')

diff --git a/juick-server/src/main/resources/db/migration/V1.2__Drop telegram_chats.sql b/juick-server/src/main/resources/db/migration/V1.2__Drop telegram_chats.sql
new file mode 100644
index 00000000..c8faee0d
--- /dev/null
+++ b/juick-server/src/main/resources/db/migration/V1.2__Drop telegram_chats.sql	
@@ -0,0 +1,2 @@
+INSERT INTO telegram(tg_id, tg_name, loginhash) SELECT chat_id AS tg_id, 'Anonymous', UUID() FROM telegram_chats;
+DROP TABLE telegram_chats;
\ No newline at end of file
-- 
cgit v1.2.3

