Subject Re: [firebird-support] embeded. Trigger doesn't fire?
Author Alexandre Benson Smith
Sergio H. Gonzalez wrote:
> [Firebird-2.1.2.18118-0]
>
> Hello, this is my first embeded project, so I might be missing something. I
> can't find the problem...
> It's any chance that a trigger is not being fired?
>
> I have this very simple trigger and I keep geting PK violation
>
> -----
> CREATE OR ALTER TRIGGER CONSULTAS_MC_BI0 FOR CONSULTAS_MC
> ACTIVE BEFORE INSERT POSITION 0
> AS
> begin
> if ((new.id <= 0) or (new.id is null)) then
>

Did you checked to see if for some reason new.id is already populated
with 0 ?

see you !

--
Alexandre Benson Smith
Development
THOR Software e Comercial Ltda
Santo Andre - Sao Paulo - Brazil
www.thorsoftware.com.br