Re: adddepend and partial indexes

Поиск
Список
Период
Сортировка
От Stephan Szabo
Тема Re: adddepend and partial indexes
Дата
Msg-id 20030617074151.J95725-100000@megazone23.bigpanda.com
обсуждение исходный текст
Ответ на adddepend and partial indexes  ("SZŰCS Gábor" <surrano@mailbox.hu>)
Ответы Re: adddepend and partial indexes  (Bruno Wolff III <bruno@wolff.to>)
Re: adddepend and partial indexes  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
On Tue, 17 Jun 2003, [iso-8859-2] SZ�CS G�bor wrote:

> Dear Fellows,
>
> Couldn't find a list on adddepend, nor this problem via Google nor search at
> postgresql.org, so here it goes.
>
> Adddepend seems to have problem with partial indexes. Below is an example.
> I can see the bugous regular subst in the perl script and I'd probably be
> able to correct it, but I don't know how to use ALTER TABLE to add a partial
> UNIQUE constraint (or shouldn't I add it at all?)

AFAIK there's no such thing as a partial unique constraint so the index
should probably just be left alone.

> Also, I can't see the meaning of the second regular subst (as shown below).

Hmm, I'd have guessed it was to take off index opclass information, but it
doesn't seem to do that (and doing so seems incorrect if its an index
using a non-default opclass).

> ------------------------------- 7.3.2
> adddepend -------------------------------
> ------------------------------- Func:
> findUniqueConstraints -------------------
> # ...
>     # Fetch vars
>     my $constraint_name = $row->{'index_name'};
>     my $table = $row->{'table_name'};
>     my $columns = $row->{'constraint_definition'};
>
>     # Extract the columns from the index definition
>     $columns =~ s|.*\(([^\)]+)\).*|$1|g;
>     $columns =~ s|([^\s]+)[^\s]+_ops|$1|g;


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Sort memory not being released
Следующее
От: Jonathan Bartlett
Дата:
Сообщение: Re: postgreSQL on NAS/SAN?