Re: Partial aggregates pushdown
| От | Zhihong Yu | 
|---|---|
| Тема | Re: Partial aggregates pushdown | 
| Дата | |
| Msg-id | CALNJ-vTQ-kUz0OE7ZBoo-C7sviUv4Sp8HGR0s9wKi8EoW5ZxKQ@mail.gmail.com обсуждение исходный текст  | 
		
| Ответ на | Partial aggregates pushdown (Alexander Pyhalov <a.pyhalov@postgrespro.ru>) | 
| Ответы | 
                	
            		Re: Partial aggregates pushdown
            		
            		 | 
		
| Список | pgsql-hackers | 
Hi,
		
	w.r.t. 0001-Partial-aggregates-push-down-v03.patch
For partial_agg_ok(),
+   if (agg->aggdistinct || agg->aggvariadic || agg->aggkind != AGGKIND_NORMAL || agg->aggorder != NIL)
+ ok = false;
+ ok = false;
Since SearchSysCache1() is not called yet, you can return false directly.
+       if (aggform->aggpartialpushdownsafe != true)
The above can be written as:
       if (!aggform->aggpartialpushdownsafe)
For build_conv_list():
+           Oid         converter_oid = InvalidOid;
+
+ if (IsA(tlentry->expr, Aggref))
+
+ if (IsA(tlentry->expr, Aggref))
...
+           }
+ convlist = lappend_oid(convlist, converter_oid);
+ convlist = lappend_oid(convlist, converter_oid);
Do you intend to append InvalidOid to convlist (when tlentry->expr is not Aggref) ?
Cheers
В списке pgsql-hackers по дате отправления: