Re: BUG #16585: Wrong filtering on a COALESCE field after using GROUPING SETS

Поиск
Список
Период
Сортировка
От Andy Fan
Тема Re: BUG #16585: Wrong filtering on a COALESCE field after using GROUPING SETS
Дата
Msg-id CAKU4AWrbKtXEzwMogaJTTK_xovoesrb6ERNHQB5dFMWQngHXGQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: BUG #16585: Wrong filtering on a COALESCE field after using GROUPING SETS  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs


The scheme I've been thinking about for clarifying the nullability
semantics of Vars might eventually provide a nicer answer for this,
but we haven't got it today.

                        regards, tom lane



With this direction, how about maintaining a RelOptInfo->notnullattrs (BitmapSet *)
attrs,  which might be accessed in a more efficient way?  We should set it to nullattrs
if it exists in groupSet clause.  I introduced this attribute in  UniqueKey patch [1] 
(patch 0001),  but it is not maintained in baserelonly now. I think we can expand it
 for other types of rel as well.  

However both implementations can avoid the issue here, but still make it impossible 
to push down an qual even if it references all the exprs in the groupset, am I right?



-- 
Best Regards
Andy Fan

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

Предыдущее
От: Andrew Gierth
Дата:
Сообщение: Re: BUG #16585: Wrong filtering on a COALESCE field after using GROUPING SETS
Следующее
От: Andy Fan
Дата:
Сообщение: Re: BUG #16585: Wrong filtering on a COALESCE field after using GROUPING SETS