Re: UNIQUE constraint and indexing
GH <grasshacker@over-yonder.net>
From: "Daniel M . Kurry" <grasshacker@over-yonder.net>
To: Arcady Genkin <a.genkin@utoronto.ca>
Cc: pgsql-general@postgresql.org
Date: 2001-09-28T11:41:38Z
Lists: pgsql-general
On Thu, Sep 27, 2001 at 06:30:50PM -0400, some SMTP stream spewed forth: > Is the index, created implicitely by "UNIQUE" constraint, the same > kind as created explicitely with "CREATE INDEX"? In other words, > is the following piece of SQL redundant? > > create table foo ( > bar serial primary key, > baz text not null unique ); > create index foo_baz_idx on foo(baz); Yes, to the best of my knowledge. Daniel M. Kurry > Many thanks, > -- > Arcady Genkin > i=1; while 1, hilb(i); i=i+1; end