| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Gerardo Herzig <gherzig(at)fmed(dot)uba(dot)ar> |
| Cc: | pgsql-sql(at)postgresql(dot)org |
| Subject: | Re: finding UNIQUES in information_schema |
| Date: | 2009-04-16 20:09:56 |
| Message-ID: | 3622.1239912596@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-sql |
Gerardo Herzig <gherzig(at)fmed(dot)uba(dot)ar> writes:
> Tom Lane wrote:
>> No, they contain information about constraints, period. How did you
>> create those indexes? If you made them via SQL-standard PRIMARY KEY or
>> UNIQUE constraint syntax, they should show in the information_schema.
>> Otherwise not.
> Well, i just dont get it.
No, apparently not. The term "constraint" in this context has a very
specific meaning; it's talking about the CONSTRAINT syntax in CREATE
TABLE or ALTER TABLE. This is per SQL specification. Indexes are an
implementation detail that the standard doesn't concern itself with;
therefore anything you do with CREATE INDEX is outside the standard and
is not reflected in the standard-defined information_schema.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Gerardo Herzig | 2009-04-16 20:44:19 | Re: finding UNIQUES in information_schema |
| Previous Message | Gerardo Herzig | 2009-04-16 19:33:16 | finding UNIQUES in information_schema |