Re: [GENERAL] listing relations

2009-06-11 Thread Greg Smith
On Thu, 11 Jun 2009, Brandon Metcalf wrote: Is there a "\" command to show all tables in the current search path? SELECT nspname,relname,relkind FROM pg_class c, pg_namespace n WHERE c.relnamespace = n.oid AND relkind='r' AND nspname !~ '^pg_toast' AND nspname = ANY(current_schem

Re: [GENERAL] listing relations

2009-06-11 Thread Brandon Metcalf
t == t...@sss.pgh.pa.us writes: t> Brandon Metcalf writes: t> > Is there a "\" command to show all tables in the current search path? t> Even ones that are masked by earlier search_path entries? No. Correct. Just wondering if there was something undocumented :) t> You could craft some ma

Re: [GENERAL] listing relations

2009-06-11 Thread Tom Lane
Brandon Metcalf writes: > Is there a "\" command to show all tables in the current search path? Even ones that are masked by earlier search_path entries? No. You could craft some manual query on pg_class, no doubt. regards, tom lane -- Sent via pgsql-general mailing li

Re: [GENERAL] listing relations

2009-06-11 Thread Brandon Metcalf
r == r...@iol.ie writes: r> On 11/06/2009 21:39, Brandon Metcalf wrote: r> > Is there a "\" command to show all tables in the current search path? r> \dt r> \? is your friend Nope. You didn't read the entire thread. If you do, you'll see why \dt isn't the answer. I'm well aware of

Re: [GENERAL] listing relations

2009-06-11 Thread Raymond O'Donnell
On 11/06/2009 21:39, Brandon Metcalf wrote: > Is there a "\" command to show all tables in the current search path? \dt \? is your friend Ray. -- Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland r...@iol.ie Galw

Re: [GENERAL] listing relations

2009-06-11 Thread Brandon Metcalf
t == t...@sss.pgh.pa.us writes: t> Brandon Metcalf writes: t> > Something interesting I've noticed. If I have a table by the same t> > name in two different schemas, say public and foo, and my search path t> > is set to 'public, foo', \d without an argument lists only the one in t> > public

Re: [GENERAL] listing relations

2009-06-11 Thread Tom Lane
Brandon Metcalf writes: > Something interesting I've noticed. If I have a table by the same > name in two different schemas, say public and foo, and my search path > is set to 'public, foo', \d without an argument lists only the one in > public. That's intentional. It's designed to show the sam