Error running a Firebird Trigger

Asked

Viewed 930 times

1

I have the following Trigger generated in my database:

SET TERM ^ ;



CREATE OR ALTER TRIGGER ATUALIZA_CODNCM FOR EST_ADICIONAIS
ACTIVE BEFORE INSERT OR UPDATE POSITION 0
AS
begin
UPDATE est_adicionais

set id_ncm = (select ncm.id from est_adicionais inner join ncm on
                            (est_adicionais.ncm = ncm.numero)
                            where est_adicionais.ncm = new.ncm and est_adicionais.codigo = new.codigo)
                            where codigo = new.codigo;

end
^


SET TERM ; ^

Only when executing the command below has the following output:

update est_adicionais e set e.st = '010' WHERE e.codigo = 135;

Exit:

Invalid token.
invalid request BLR at offset 258.
function HASHMD5 is not defined.
module name or entrypoint could not be found.

When running separately the Select and Update 2 commands are executed without any problem.

  • You have the UDF HASHMD5 in your BD?

  • @wesleyluan believe I should not have? This comes native or you need to add separately?

  • Is there a Rigger that is using this UDF ?

  • How do I identify the use of this UDF?

1 answer

1


The problem was due to Firebird installed on the computer being corrupted missing the UDF HASHMD5, then in case it needed to run it would accuse the lack of such add-on.

To remedy the problem was done the removal of the components of Firebird and made again the installation of the same.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.