Thread: Finding filenames for tables
I must be having a bad search-engine day. How do I join pg_class and pg_database to determine OID/tablename pairs for a given database? I can't find anything to join on in those tables. I'm just grepping output right now, but I'd like to do more complicated things in the future, thus my question. -j -- Jamie Lawrence jal@jal.org
Jamie Lawrence wrote: >How do I join pg_class and pg_database to determine OID/tablename >pairs for a given database? I can't find anything to join on in those >tables. I'm just grepping output right now, but I'd like to do more >complicated things in the future, thus my question. > > Jamie, you don't need to join since pg_class is specific for a database. You cannot see any classes from a different database in pg_class. In contrast, pg_database is server-wide mirrored. Regards, Andreas
On Tue, 13 May 2003, Andreas Pflug wrote: > you don't need to join since pg_class is specific for a database. You > cannot see any classes from a different database in pg_class. In > contrast, pg_database is server-wide mirrored. Thank you! I had sufficiently confused myself that I didn't even think to wonder if this was the case or not. Thanks again. -j -- Jamie Lawrence jal@jal.org "It only takes 20 years for a liberal to become a conservative without changing a single idea." - Robert Anton Wilson