Re: CREATE TABLE LIKE INCLUDING INDEXES support

Поиск
Список
Период
Сортировка
От NikhilS
Тема Re: CREATE TABLE LIKE INCLUDING INDEXES support
Дата
Msg-id d3c4af540705180026o3921849cicc17c02fcc593ec@mail.gmail.com
обсуждение исходный текст
Ответ на Re: CREATE TABLE LIKE INCLUDING INDEXES support  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: CREATE TABLE LIKE INCLUDING INDEXES support  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-patches
Hi,


[ remembering previous discussions more clearly... ]  Actually there
is a concrete problem here: unique constraints are supposed to be
represented in the information_schema views, and there is no
spec-compliant way to do that for a constraint on something other than
a column.  We'd have to guess at what the SQL committee would do about
that, and the odds of guessing exactly right don't seem encouraging.

Considering that a unique index is a unique constraint, then isn't allowing expressional unique indexes contradictory to the above?

It seems that "CREATE UNIQUE INDEX" currently does not pass isconstraint as true to DefineIndex, otherwise  index_create() would have cribbed with:

"constraints cannot have index expressions" error.

Since this patch is going to consider creating unique/primary indexes assuming them to be constraints, IMHO we should be uniform about unique constraints semantics.

That might mean that we only support expressionless, non-predicate indexes via "INCLUDING CONSTRAINTS"?

Regards,
Nikhils

--
EnterpriseDB               http://www.enterprisedb.com

В списке pgsql-patches по дате отправления:

Предыдущее
От: "Pavel Stehule"
Дата:
Сообщение: Re: Updateable cursors patch
Следующее
От: Heikki Linnakangas
Дата:
Сообщение: Re: Seq scans status update