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.