Re: [PATCH v5] Show detailed table persistence in \dt+

Поиск
Список
Период
Сортировка
От Fabien COELHO
Тема Re: [PATCH v5] Show detailed table persistence in \dt+
Дата
Msg-id alpine.DEB.2.21.1904290831550.8815@lancre
обсуждение исходный текст
Ответ на Re: [PATCH v5] Show detailed table persistence in \dt+  (David Fetter <david@fetter.org>)
Ответы Re: [PATCH v5] Show detailed table persistence in \dt+  (David Fetter <david@fetter.org>)
Список pgsql-hackers
Hello David,

> My mistake. Fixed.

About v6: applies, compiles, make check ok.

Code is ok.

Maybe there could be a comment to tell that prior version are not 
addressed, something like:

     ...
   }
   /* else do not bother guessing the temporary status on old version */

No tests, pending an added TAP test infrastructure for psql.

I have a question a out the index stuff: indexes seem to appear as entries 
in pg_class, and ISTM that they can be temporary/unlogged/permanent as 
attached to corresponding objects. So the guard is not very useful and it 
could make sense to show the information on indexes as well.

After removing the guard:

  postgres=# \dtmv+ *foo*
                                     List of relations
  ┌───────────┬──────┬───────────────────┬────────┬─────────────┬─────────┬─────────────┐
  │  Schema   │ Name │       Type        │ Owner  │ Persistence │  Size   │ Description │
  ├───────────┼──────┼───────────────────┼────────┼─────────────┼─────────┼─────────────┤
  │ pg_temp_3 │ foo  │ table             │ fabien │ temporary   │ 0 bytes │             │
  │ public    │ mfoo │ materialized view │ fabien │ permanent   │ 0 bytes │             │
  │ public    │ ufoo │ table             │ fabien │ unlogged    │ 0 bytes │             │
  └───────────┴──────┴───────────────────┴────────┴─────────────┴─────────┴─────────────┘
  (3 rows)

  postgres=# \di+ *foo*
                                      List of relations
  ┌───────────┬───────────┬───────┬────────┬───────┬─────────────┬────────────┬─────────────┐
  │  Schema   │   Name    │ Type  │ Owner  │ Table │ Persistence │    Size    │ Description │
  ├───────────┼───────────┼───────┼────────┼───────┼─────────────┼────────────┼─────────────┤
  │ pg_temp_3 │ foo_pkey  │ index │ fabien │ foo   │ temporary   │ 8192 bytes │             │
  │ public    │ ufoo_pkey │ index │ fabien │ ufoo  │ unlogged    │ 16 kB      │             │
  │ public    │ ufoou     │ index │ fabien │ ufoo  │ unlogged    │ 16 kB      │             │
  └───────────┴───────────┴───────┴────────┴───────┴─────────────┴────────────┴─────────────┘
  (3 rows)

Is there a special reason not to show it?

-- 
Fabien.

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

Предыдущее
От: Fabien COELHO
Дата:
Сообщение: Re: [PATCH v4] Add \warn to psql
Следующее
От: David Rowley
Дата:
Сообщение: Re: Speed up build on Windows by generating symbol definition in batch