Re: [GENERAL] CONSTRAINT does not show when applying a EXCLUDE constraint

2010-12-28 Thread InterRob
SOLVED: I should use the "CREATE UNIQUE INDEX ... ON ..." command, on an existing table. This cannot be done inline within the CREATE TABLE command. Thanks all, for your help. Rob 2010/12/28 InterRob > Dear Tom, > > Thanks for your hints; it is indeed funny (as mentioned by Guillaume) how > i

Re: [GENERAL] CONSTRAINT does not show when applying a EXCLUDE constraint

2010-12-28 Thread InterRob
Dear Tom, Thanks for your hints; it is indeed funny (as mentioned by Guillaume) how indexes and constraints are being mixed up -- mentioned either in the Indexes or in Constraints department. Pgsql and PgAdmin make different choices here. And well, given their implementation these choices can both

Re: [GENERAL] CONSTRAINT does not show when applying a EXCLUDE constraint

2010-12-27 Thread Guillaume Lelarge
Le 27/12/2010 22:02, Richard Broersma a écrit : > On Mon, Dec 27, 2010 at 12:50 PM, InterRob wrote: >> pgsql Command "\d test" produces the following: >>Table "public.test" >>Column | Type | Modifiers >> +-+--- >> object_id | integer | >> subject_id

Re: [GENERAL] CONSTRAINT does not show when applying a EXCLUDE constraint

2010-12-27 Thread Tom Lane
Richard Broersma writes: > On Mon, Dec 27, 2010 at 12:50 PM, InterRob wrote: >> pgsql Command "\d test" produces the following: >>Table "public.test" >>Column | Type | Modifiers >> +-+--- >> object_id | integer | >> subject_id | integer | >> Indexes

Re: [GENERAL] CONSTRAINT does not show when applying a EXCLUDE constraint

2010-12-27 Thread Richard Broersma
On Mon, Dec 27, 2010 at 12:50 PM, InterRob wrote: > pgsql Command "\d test" produces the following: >        Table "public.test" >    Column   |  Type   | Modifiers > +-+--- >  object_id  | integer | >  subject_id | integer | > Indexes: >     "EXCL_double_combi" EXCLUDE

Re: [GENERAL] CONSTRAINT does not show when applying a EXCLUDE constraint

2010-12-27 Thread InterRob
Sorry: that is because the major part of my E-mail got chopped off... Herewith I am resending it: --- Dear list, To rule out any double combination of two identifiers, in any order, I applied the following constraint to a table: CREATE TABLE test( o

Re: [GENERAL] CONSTRAINT does not show when applying a EXCLUDE constraint

2010-12-27 Thread Richard Broersma
On Mon, Dec 27, 2010 at 8:31 AM, Rob Marjot wrote: > Dear list, > To rule out any double combination of two identifiers, in any order, I > applied the following constraint to a table: > CREATE TABLE test(object_id INTEGER, subject_id INTEGER, CONSTRAINT I don't see the definition of your constrai

[GENERAL] CONSTRAINT does not show when applying a EXCLUDE constraint

2010-12-27 Thread Rob Marjot
Dear list, To rule out any double combination of two identifiers, in any order, I applied the following constraint to a table: CREATE TABLE test(object_id INTEGER, subject_id INTEGER, CONSTRAINT

[GENERAL] CONSTRAINT does not show when applying a EXCLUDE constraint -- and what about Enterprise Architect?

2010-12-27 Thread InterRob
Dear list, To rule out any double combination of two identifiers, in any order, I applied the following constraint to a table: CREATE TABLE test( object_id INTEGER, subject_id INTEGER, CONSTRAINT "EXCL_double_combi" EXCLUDE USING btree (imm_LEAST(subject_id, object_id) WITH =, imm_GREATEST(