Re: [HACKERS] Partition-wise join for join between (declaratively)partitioned tables

Поиск
Список
Период
Сортировка
От Amit Langote
Тема Re: [HACKERS] Partition-wise join for join between (declaratively)partitioned tables
Дата
Msg-id 2d4e9d54-0d08-9aa0-6359-6b776b2f5438@lab.ntt.co.jp
обсуждение исходный текст
Ответ на Re: [HACKERS] Partition-wise join for join between (declaratively)partitioned tables  (Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>)
Ответы Re: Partition-wise join for join between (declaratively)partitioned tables  (Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>)
Список pgsql-hackers
Hi Ashutosh,

On 2017/03/23 21:48, Ashutosh Bapat wrote:
>>> I have fixed all the issues reported till now.

In patch 0007, the following code in have_partkey_equi_join() looks
potentially unsafe:
       /*        * If the clause refers to different partition keys from        * both relations, it can not be used
forpartition-wise join.        */       if (ipk1 != ipk2)           continue;
 
       /*        * The clause allows partition-wise join if only it uses the same        * operator family as that
specifiedby the partition key.        */       if (!list_member_oid(rinfo->mergeopfamilies,
part_scheme->partopfamily[ipk1]))          continue;
 

What if ipk1 and ipk2 both turn out to be -1? Accessing
part_schem->partopfamily[ipk1] would be incorrect, no?

Thanks,
Amit





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

Предыдущее
От: Amit Kapila
Дата:
Сообщение: Re: [HACKERS] pageinspect and hash indexes
Следующее
От: Kuntal Ghosh
Дата:
Сообщение: Re: [HACKERS] BUG: pg_dump generates corrupted gzip file in Windows