S
S
swaro2022-02-05 11:04:27
PostgreSQL
swaro, 2022-02-05 11:04:27

How to make Id like posts in Telegram?

If you copy a link to a post from a Telegram channel, you get a link like t.me/c/(channel id here)/(post id here). If you do this with different channels, then you can see that the "space" (if you can call it that) of identifiers for posts for each channel is different. Thus, channel A and channel B can (will) have posts with the same id. Question: how can this be implemented in PostgreSQL? With the transition to the post by the link, you can still come up with something with OFFSETs, but then what about getting this very id when selecting?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
Konstantin Tsvetkov, 2022-02-05
@tsklab

Composite primary key. How to get ID .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question