Re: BUG #2848: information_schema.key_column_usage does not work

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Tony Marston" <tony(at)marston-home(dot)demon(dot)co(dot)uk>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #2848: information_schema.key_column_usage does not work
Date: 2006-12-21 15:33:41
Message-ID: 19543.1166715221@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"Tony Marston" <tony(at)marston-home(dot)demon(dot)co(dot)uk> writes:
> I have the following query:

> SELECT key_column_usage.*,constraint_type
> FROM information_schema.key_column_usage
> LEFT JOIN information_schema.table_constraints USING
> (table_schema,table_name,constraint_name)
> WHERE table_schema='whatever' and table_name='whatever'
> ORDER BY constraint_type, constraint_name, ordinal_position

> This works when I am logged on as 'postgres', but if I try it after logging
> on with a different username it fails with "ERROR: relation with OID 18635
> does not exist".

I tried to reproduce this, but it works for me ...

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Norman Yamada 2006-12-21 15:45:40 postgresql 8.2.0 -- LIMIT NULL crashes server
Previous Message Tom Lane 2006-12-21 15:02:44 Re: BUG #2850: Cannot select from information_schema.schemat