loading...

re: How to build unique indexes in PostgreSQL on large text VIEW POST

TOP OF THREAD FULL DISCUSSION
re: Hi @rhymes , Great post. TIL about the limit on size of what can be indexed. A buffer page is generally around 8kb so looks like 2.5 kb is maximum ...
 

Hi Raunak!

  1. No, it's just used to avoid accidental double posting mostly
  2. It's not queried so it doesn't really matter in this case but yeah, in general it does matter, great point!
  3. We don't have length CHECK constraints in the database, so it's one of those things that it's still only at the application level
  4. It would mean that the hash needs to be updated at the code level at each "article save", which means that we're back to depending on Rails to check uniqueness

Hope this clears a bit :) Great questions!

code of conduct - report abuse