On 11/15/20 9:03 AM, Luca Ferrari wrote:
Hi all,
I've a couple of doubts about toast:
1) is a REINDEX DATABASE hitting also toast tables or they need to be
reindexed manually?

https://www.postgresql.org/docs/current/sql-reindex.html

"DATABASE

Recreate all indexes within the current database. Indexes on shared system catalogs are also processed. This form of REINDEX cannot be executed inside a transaction block.
"

"TABLE

Recreate all indexes of the specified table. If the table has a secondary “TOAST” table, that is reindexed as well.
"

Database --> Table --> TOAST table.

2) while executing a query against toasted values I got this debug
message that I don't know what is meaning

This happened when you where doing the REINDEX DATABASE?

DEBUG:  building index "pg_toast_33875_index" on table "pg_toast_33875" serially

The query I was executing was:
SELECT  lower( f::text )  ||  lower( t::text )  FROM crashy_table
WHERE id = '16385'
via a plpgsql PERFORM.

Thanks,
Luca




--
Adrian Klaver
adrian.kla...@aklaver.com


Reply via email to