On Tue, Jul 23, 2024 at 4:36 PM Peter Eisentraut <pe...@eisentraut.org> wrote: > The sorting isn't the problem. We have a versioning mechanism for > collations. What we do with the version information is clearly not > perfect yet, but the mechanism exists and you can hack together queries > that answer the question, did anything change here that would affect my > indexes. And you could build more tooling around that and so on.
In my experience, sorting is, overwhelmingly, the problem. What people complain about is that they do an upgrade - of PG or some OS package - and then their indexes are broken. Or their partition bounds are broken. That we have versioning information that someone could hypothetically know how to do something useful with is not really useful, because nobody actually knows how to do it, and there's nothing to trigger them to do it in the first place. People don't think "oh, I'm running dnf update, I better run undocumented queries against the PostgreSQL system catalogs to see whether my system is going to melt afterwards." What needs to happen is that when you do something that breaks something, something notices automatically and tells you and gives you a way to get it fixed again. Or better yet, when you do something that would break something as things stand today, some kind of versioning logic kicks in and you keep the old behavior and nothing actually breaks. -- Robert Haas EDB: http://www.enterprisedb.com