Re: [HACKERS] REPLICA IDENTITY FULL

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: [HACKERS] REPLICA IDENTITY FULL
Дата
Msg-id 20170623170521.zn5pwvqsjyv73j2y@alvherre.pgsql
обсуждение исходный текст
Ответ на Re: [HACKERS] REPLICA IDENTITY FULL  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: [HACKERS] REPLICA IDENTITY FULL  (Andres Freund <andres@anarazel.de>)
Список pgsql-hackers
Tom Lane wrote:
> Peter Eisentraut <peter.eisentraut@2ndquadrant.com> writes:
> > Any thoughts about keeping datumAsEqual() as a first check?  I did some
> > light performance tests, but it was inconclusive.
> 
> Seems like it would tend to be a win if, in fact, the values are
> usually equal.  If they're usually not, then it's a loser.  Do
> we have any feeling for which case is more common?

What about keeping the datumIsEqual test for fixed length pass-by-value
types (I'm mostly thinking about fixed-width integers here ...) and
always use the full blown equality comparison for anything more
elaborate than that?

Though, thinking about it, maybe the datumIsEqual test would give the
wrong answer for floating point values, and there'd be no fallback to
equality with the logic I propose.  But then maybe that's all right ---
who in their right minds would use floating point columns as part of
replica identity ...?

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: [HACKERS] Setting pd_lower in GIN metapage
Следующее
От: Andres Freund
Дата:
Сообщение: Re: [HACKERS] REPLICA IDENTITY FULL