Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

I have a script access oracle thru dbi, one of the update statement receives sqlcode -20219 from time to time. I googled this code, but got nothing. Does anyone know what kind of error is that?

Replies are listed 'Best First'.
Re: [OT] DBI oracle sqlcode -20219
by jdalbec (Deacon) on Jan 27, 2005 at 02:19 UTC
    Oracle Error Documentation Errors in the range -20999..-20000 are application-defined errors generated by calling the RAISE_APPLICATION_ERROR() stored procedure. If you're just updating a table then the update must be setting off a trigger that raises the -20219 error.

      I don't think there is a trigger, but I will check tomorrow. One thing though, this table has foreign key defined, don't know whether this matters?

        Guess irrelevant, as the update statement does not change any of the foreign key ;-)

      Thanks. There was a trigger.

Re: DBI oracle sqlcode -20219
by Errto (Vicar) on Jan 27, 2005 at 02:19 UTC
    Please show us the code that generates this error and the full text of the error message. Also try passing the option RaiseError => 1 when you call DBI->connect so that actual error messages will be dumped when they occur. In Oracle, all error messages look something like [ORA-00502] Big Bad Error or something like that.
    A reply falls below the community's threshold of quality. You may see it by logging in.