Re: Declarative partitioning
От | Amit Langote |
---|---|
Тема | Re: Declarative partitioning |
Дата | |
Msg-id | 2e19afef-8b5d-da91-cf5a-ab73511fba5a@lab.ntt.co.jp обсуждение исходный текст |
Ответ на | Re: Declarative partitioning (Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>) |
Список | pgsql-hackers |
On 2016/08/10 19:18, Ashutosh Bapat wrote: > FOR VALUE clause of a partition does not allow a constant expression like > (10000/5 -1). It gives syntax error > regression=# create table pt1_p1 partition of pt1 for values start (0) end > ((10000/5) - 1); > ERROR: syntax error at or near "(" > LINE 1: ...pt1_p1 partition of pt1 for values start (0) end ((10000/5) ... > > Shouldn't we allow constant expressions here? > > If this has been already discussed, please forgive me and point out the > relevant mail chain. Yes, the only allowed values there are string literals, numeric values and null. Decision to change to it followed from this comment: "Also, I don't think allowing an a_expr as a bound is remotely sensible - I think you should allow only Sconst, NumericOnly, NULL, and UNBOUNDED." https://www.postgresql.org/message-id/CA%2BTgmoZ1ZMCyGR3b9yvGDq79xYLMnJQwhwn5GVs_GsvPiySDxw%40mail.gmail.com Thanks, Amit
В списке pgsql-hackers по дате отправления: