Tom Lane wrote:
It strikes me that if we were willing to throw code at the problem, we could make it work like this: ... This would properly throw error for cases where you'd passed the wrong catalog's OID column to pg_relation_size.
Yeah, you're right that is the proper way to handle this. As the problem isn't that serious once you're aware of it, I don't see a large amount of motivation to work on that now though, if that's what it will take to fix. And Tomas seemed satisfied with a workaround too. I just added a TODO item pointing to your suggested implementation so it's more likely people will stumble onto the relevant trivia here on their own, and maybe some day a patch will get written to implement that idea too.
-- Greg Smith, 2ndQuadrant US greg@xxxxxxxxxxxxxxx Baltimore, MD PostgreSQL Training, Services and Support www.2ndQuadrant.us Author, "PostgreSQL 9.0 High Performance" Pre-ordering at: https://www.packtpub.com/postgresql-9-0-high-performance/book -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general