From: David H. <dav...@me...> - 2011-07-15 11:38:50
|
Op 15-07-11 13:27, Michael Paquier schreef: > On Fri, Jul 15, 2011 at 8:01 PM, David Hartveld > <dav...@me... <mailto:dav...@me...>> wrote: > > After playing around with postgres-xc 0.9.5, I wanted to give my actual > application a try. I get the following error message when setting up the > base schema: "ERROR: Postgres-XC does not support DEFAULT with > non-immutable functions yet". This happens when setting up a column as > follows (this is btw copied verbatim from the postgresql documentation, > explaining how a serial type works): > > CREATE SEQUENCE tablename_colname_seq; > CREATE TABLE tablename ( > colname integer NOT NULL DEFAULT nextval('tablename_colname_seq') > ); > ALTER SEQUENCE tablename_colname_seq OWNED BY tablename.colname; > > I've read that (global) sequences and serial are not yet supported. I > checked the roadmap and couldn't find mention of this explicitly. I was > wondering if support is planned, and if so, when? (And if not, why :-). > > > Supporting serial and default values with nextval is pretty complicated > because sequences are only created on Coordinators. It is not currently > taken into account in the development plans. > However, I am working currently on the support of this feature because > me too I believe it is important to support it. > My patch is half-way done, and needs some rework on the planner side. > I may have some results within the next couple of weeks. I understand the problem, however, the application for which I'm experimenting does need the functionality (currently). I might be interested in testing your patches, do let me know if you need some testing done! Greetings, David |