Re: Duplicate key insert question - Mailing list pgsql-general

From Maksim Likharev
Subject Re: Duplicate key insert question
Date
Msg-id 56510AAEF435D240958D1CE8C6B1770A016D2D80@mailc03.aurigin.com
Whole thread Raw
In response to Duplicate key insert question  (Jean-Christian Imbeault <jc@mega-bucks.co.jp>)
List pgsql-general
Yes, but for MSSQL unique index with ignore duplicate in reality
will reject all duplicates.
Another word if you are trying to insert 2 identical values
you will insert none.
Do search using IF EXISTS SELECT ... or LEFT OUTER JOIN ... WHERE ... IS
NULL.
works pretty fast.


-----Original Message-----
From: Jean-Christian Imbeault [mailto:jc@mega-bucks.co.jp]
Sent: Tuesday, July 01, 2003 5:21 PM
To: Dann Corbit
Cc: pgsql-general@postgresql.org
Subject: Re: [GENERAL] Duplicate key insert question


Dann Corbit wrote:
>
> SQL*Server has a nice feature for this.

Ok ... is there a way to achieve the same effect in postgres?

Thanks,

Jean-Christian Imbeault


---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
      subscribe-nomail command to majordomo@postgresql.org so that your
      message can get through to the mailing list cleanly

pgsql-general by date:

Previous
From: "Reuben D. Budiardja"
Date:
Subject: Re: postgresql.org is unreliable
Next
From: Jean-Christian Imbeault
Date:
Subject: Re: Duplicate key insert question