Re: Partitionin with check functions

Поиск
Список
Период
Сортировка
От Harald Fuchs
Тема Re: Partitionin with check functions
Дата
Msg-id pu63hr3v5i.fsf@srv.protecting.net
обсуждение исходный текст
Ответ на Partitionin with check functions  (fatih ozturk <ozturkfa@yahoo.com>)
Список pgsql-admin
In article <2499.1238420859@sss.pgh.pa.us>,
Tom Lane <tgl@sss.pgh.pa.us> writes:

> In particular, a constraint like "sel=123" is *not* going to lead the
> planner to draw any conclusions about the value of "mod(sel,6)".
> Now, if you'd written "WHERE mod(sel,6)=3", I think it would draw
> the right conclusions.

Yes, it does.  It might be worthwile to use

  WHERE sel=123 AND mod(sel,6)=3

I think you could use a rule to add the mod() condition automatically.

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Partitionin with check functions
Следующее
От: toni hernández
Дата:
Сообщение: copy command and column attribute