conditional insert

From: Pau Marc Muñoz Torres <paumarc(at)gmail(dot)com>
To: pgsql general <pgsql-general(at)postgresql(dot)org>
Subject: conditional insert
Date: 2011-09-05 09:38:34
Message-ID: CADFuJLjCF6fmxswgS033EFyofmbJFy+J0ToUvwTCDDLYj+nr3Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi follk

i trying to performe a conditional insert into a table, indeed, what i'm
trying to do is not insert a record into the table if that record exist

googleling i found something like

insert into XX values (1,2,3) where not exist (select ....);

but i'm having and error near where...

anyone knows how do i can perfome this insert?

thanks

p

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Achilleas Mantzios 2011-09-05 09:45:13 Re: conditional insert
Previous Message Mamatha_Kagathi_Chan 2011-09-05 06:47:59 Help for Migration