This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # After running the script in logging in to your account, send "forward_unseen:mister_x:10" to your saved messages, | |
| # the bot will then forward 10 last messages of the first user with name mister_x to your saved messages. | |
| # This way you can check what people have sent you without them knowing you did. | |
| from telethon import TelegramClient, events, sync | |
| from telethon.tl.types import PeerUser | |
| api_id = # Your Telegram API id here | |
| api_hash = # Your Telegram API hash here |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -- Create a group | |
| CREATE ROLE readaccess; | |
| -- Grant access to existing tables | |
| GRANT USAGE ON SCHEMA public TO readaccess; | |
| GRANT SELECT ON ALL TABLES IN SCHEMA public TO readaccess; | |
| -- Grant access to future tables | |
| ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO readaccess; |