pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Richard Huxton <dev@archonet.com>
To: Jean-Luc Lachance <jllachan@nsd.ca>
Cc: pgsql-sql@postgresql.org
Subject: Re: Dublicates pairs in a table.
Date: Fri, 27 Sep 2002 17:37:43 +0100
Message-ID: <200209271737.43262.dev@archonet.com> (raw)
In-Reply-To: <3D94849E.4A769993@nsd.ca>
References: <000201c25d90$87230c10$6500000a@IT000>
	<200209271354.54187.dev@archonet.com>
	<3D94849E.4A769993@nsd.ca>

On Friday 27 Sep 2002 5:17 pm, Jean-Luc Lachance wrote:
> What's wrong with
> CREATE UNIQUE INDEX foo_both_uniq ON foo(a,b);
> ???

Because he specifically wanted values of ('a','b') and ('b','a') to be treated 
as equivalent (see quote).

> > >   INSERT INTO test (c1,c2) VALUES('a','c');
> > >   INSERT INTO test (c1,c2) VALUES('c','a');

Note Stephen Szabo's observation that I'd missed the obvious need for some 
separator so ('a','ab') is different from ('aa','b') - Doh!

- Richard Huxton





view thread (10+ messages)  latest in thread

Message-ID: <200209271737.43262.dev@archonet.com>
Permalink:  ../200209271737.43262.dev@archonet.com/
Also on:    postgresql.org/message-id/200209271737.43262.dev@archonet.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: dev@archonet.com, jllachan@nsd.ca
  Subject: Re: Dublicates pairs in a table.
  In-Reply-To: <200209271737.43262.dev@archonet.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox