Re: Table cannot be partiotioned using domain in argument

2018-09-11 Thread Márcio A . Sepp
Hi and thanks for answer, Nope.  The problem is suggested, if not exactly clearly explained, by the error message: casting a literal to ddate isn't a guaranteed fixed process. Wasn't clear enought to me.For example, suppose you created this table and then did alter domain ddate add check (val

Re: Table cannot be partiotioned using domain in argument

2018-09-11 Thread Tom Lane
=?iso-8859-1?Q?M=E1rcio_Ant=F4nio_Sepp?= writes: > The follow error occur: > SQL Error [42804]: ERROR: specified value cannot be cast to type ddate for > column "d" > Detalhe: The cast requires a non-immutable conversion. > I cannot use domain in this case? Nope. The problem is suggested, if

Table cannot be partiotioned using domain in argument

2018-09-11 Thread Márcio Antônio Sepp
Hi, This query works fine: create table t1 (d date) PARTITION BY RANGE (d); CREATE TABLE t1_p1 PARTITION OF t1 FOR VALUES FROM ('2000-01-01') TO ('2019-01-01'); Same query, but now (using domain): CREATE DOMAIN ddate AS date; create table t1 (d ddate) PARTI