Re: Auto Partitioning

Поиск
Список
Период
Сортировка
От Markus Schiltknecht
Тема Re: Auto Partitioning
Дата
Msg-id 46165475.5070009@bluegap.ch
обсуждение исходный текст
Ответ на Re: Auto Partitioning  ("Simon Riggs" <simon@2ndquadrant.com>)
Ответы Re: Auto Partitioning  ("Simon Riggs" <simon@2ndquadrant.com>)
Список pgsql-hackers
Simon Riggs wrote:
> i.e. if we have partitions for each year (2001, 2002, 2003 2004, 2005,
> 2006, 2007) AND we have already proved that 2005 is excluded when we
> have a WHERE clause saying year >= 2006, then we should be able to use
> the ordering to prove that partitions for 2004 and before are also
> automatically excluded.

Provided you've set up the right constraints, the current 
constraint_exclusion feature does exactly that, no?

> I'll think some more about the Merge node, but not right now.

I've looked at nodeAppend.c and nodeMergeJoin.c. Probably we can use 
much of nodeMergeJoin, just without the join? Instead returning the 
tuples as they are, but in the correct order. The nodeMergeJoin code can 
only handle two inputs (a left and a right node), but it might be 
beneficial to structure multiple merge nodes into a binary tree layout 
anyway. (I'm guessing that might reduce the amount of comparisons needed).

What do you think?

Regards

Markus


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

Предыдущее
От: Larry Rosenman
Дата:
Сообщение: Re: What X86/X64 OS's do we need coverage for?
Следующее
От: Andrew Dunstan
Дата:
Сообщение: Re: What X86/X64 OS's do we need coverage for?