trigger interruption on "SPI_execp"

From: Benoit Baudouin <benoit(dot)baudouin(at)b2i-toulouse(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: trigger interruption on "SPI_execp"
Date: 2003-06-16 15:25:22
Message-ID: 3EEDE162.3060005@b2i-toulouse.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

hi,

I table with primary key and in trigger try to insert into this table data
wich violate constrain (not uniq). When ectually executing SPI_execp I got
a message "ERROR: cannot insert a duplicate key into a unique index" and
trigger executing is aborted.
Is there some way to insert uniq data into
table without first cheking using SELECT. Because this table contain >1M
records and SELECT on it is very slow.

best regards,

Benoît Baudouin

B2i Toulouse
1 av. de l'Europe 31400 Toulouse
tel 0561003080 fax 0561003085

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Mattias Kregert 2003-06-16 15:26:23 Re: trigger interruption on "SPI_execp"
Previous Message Tom Lane 2003-06-16 14:57:37 Re: Why can't you define a table alias on an update?