Re: Confusing error message for REINDEX TABLE CONCURRENTLY

Поиск
Список
Период
Сортировка
От David Rowley
Тема Re: Confusing error message for REINDEX TABLE CONCURRENTLY
Дата
Msg-id CAKJS1f-AsAQi_1Temf04i0fafjJmLVX-HjkO5C-kcqjpGMd3mg@mail.gmail.com
обсуждение исходный текст
Ответ на Confusing error message for REINDEX TABLE CONCURRENTLY  (Ashwin Agrawal <aagrawal@pivotal.io>)
Ответы Re: Confusing error message for REINDEX TABLE CONCURRENTLY  (Michael Paquier <michael@paquier.xyz>)
Список pgsql-hackers
On Sat, 25 May 2019 at 12:06, Ashwin Agrawal <aagrawal@pivotal.io> wrote:
> Seems might be just emit the NOTICE "table xxx has no index", if really no index for concurrent and non-concurrent
case,make it consistent, less confusing and leave it there. Attaching the patch to just do that. Thoughts?
 

Would it not be better just to change the error message for the
concurrent case so that it reads: "table \"%s\" has no indexes that
can be concurrently reindexed"

Otherwise, what you have now is still confusing for partitioned tables:

postgres=# create table listp (a int primary key) partition by list(a);
CREATE TABLE
postgres=# REINDEX TABLE CONCURRENTLY listp;
psql: WARNING:  REINDEX of partitioned tables is not yet implemented,
skipping "listp"
psql: NOTICE:  table "listp" has no indexes
REINDEX

Also, I think people probably will care more about the fact that
nothing was done for that table rather than if the table happens to
have no indexes. For the non-concurrently case, that just happened to
be the same thing.

-- 
 David Rowley                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services



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

Предыдущее
От: Noah Misch
Дата:
Сообщение: Re: [HACKERS] WAL logging problem in 9.4.3?
Следующее
От: Amit Kapila
Дата:
Сообщение: Re: Fix link for v12