From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | "April Lorenzen" <outboundindex(at)gmail(dot)com> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: proper way to fix information_schema.key_column_usage view |
Date: | 2007-08-12 03:25:07 |
Message-ID: | 13312.1186889107@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
"April Lorenzen" <outboundindex(at)gmail(dot)com> writes:
> I had to feel my way carrying out this fix, and I don't know if I did
> it right - I only know that it appears I no longer have the error.
> Please confirm whether I was supposed to execute all of
> share/information_schema.sql --- or just the portion that CREATEs or
> REPLACEs key_column_usage view.
You should only have had to CREATE OR REPLACE the one view.
> I did not execute the whole share/information_schema.sql --- I only
> executed the part of it referring to the key_column_usage view and
> each of the functions necessary to support that. CREATE OR REPLACE the
> key_column_usage view gave errors otherwise for numerous missing
> functions. That worries me because it makes me think I should execute
> the whole thing. Instead I just kept adding the function definitions
> until it successfully executed.
What it sounds like to me is you had the wrong search_path set, and
so what you've done is create a new copy of the view (and supporting
functions) in whichever schema was first in your search path ---
possibly "public". This isn't a good fix. You should clean out the
extraneous view and supporting functions, and try again with
set search_path = information_schema;
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Gregory Stark | 2007-08-12 13:47:43 | Re: Problem with locks |
Previous Message | Rober Mach | 2007-08-12 02:01:07 | Re: pgcheck - data integrity check |