Re: recovering from "found xmin ... from before relfrozenxid ..."

Поиск
Список
Период
Сортировка
От Asim Praveen
Тема Re: recovering from "found xmin ... from before relfrozenxid ..."
Дата
Msg-id 1D56CEFD-E195-4E6B-B870-3383E3E8C65E@vmware.com
обсуждение исходный текст
Ответ на Re: recovering from "found xmin ... from before relfrozenxid ..."  (Ashutosh Sharma <ashu.coek88@gmail.com>)
Ответы Re: recovering from "found xmin ... from before relfrozenxid ..."  (Ashutosh Sharma <ashu.coek88@gmail.com>)
Список pgsql-hackers
Hi Ashutosh

I stumbled upon this thread today, went through your patch and it looks good.  A minor suggestion in
sanity_check_relation():

    if (rel->rd_rel->relam != HEAP_TABLE_AM_OID)
        ereport(ERROR,
                (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
                 errmsg("only heap AM is supported")));

Instead of checking the access method OID, it seems better to check the handler OID like so:

    if (rel->rd_amhandler != HEAP_TABLE_AM_HANDLER_OID)

The reason is current version of sanity_check_relation() would emit error for the following case even when the table
structureis actually heap.
 

    create access method myam type table handler heap_tableam_handler;
    create table mytable (…) using myam;

Asim

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

Предыдущее
От: Thomas Munro
Дата:
Сообщение: Re: WIP: WAL prefetch (another approach)
Следующее
От: Julien Rouhaud
Дата:
Сообщение: Re: [PG13] Planning (time + buffers) data structure in explain plan (format text)