db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel John Debrunner (JIRA)" <derby-...@db.apache.org>
Subject [jira] Commented: (DERBY-551) Allow invoking java stored procedures from inside a trigger. Make CALL a valid statement in the trigger body.
Date Sat, 08 Jul 2006 01:04:37 GMT
    [ http://issues.apache.org/jira/browse/DERBY-551?page=comments#action_12419808 ] 

Daniel John Debrunner commented on DERBY-551:

Another option is to use the existing compile time mechansim that defines what is allowed
in a context. This is the CompilerContext.getReliability() infrastructure. Bits are set in
the mask that define what operations are allowed (or not allowed, can't remember which way
the definitions go).

In this case the relability mode would be set to exclude 'modifies data' routines during compilation
of the trigger's  action statement, this would need some new bit definitions and checks in
the node for routine call.

I am concerned that your approach is limited to a single routine call, which is all that is
required now, but does not support future changes where multiple procedures can form an action
statement. The more general approach using the existing mechanisms will automatically handle
future changes.

> Allow invoking java stored procedures from inside a trigger. Make CALL a valid statement
in the trigger body.
> -------------------------------------------------------------------------------------------------------------
>          Key: DERBY-551
>          URL: http://issues.apache.org/jira/browse/DERBY-551
>      Project: Derby
>         Type: New Feature

>   Components: SQL
>     Versions:
>  Environment: All platforms
>     Reporter: Satheesh Bandaram
>     Assignee: Deepa Remesh
>      Fix For:
>  Attachments: ProcedureInTrigger_Tests_v1.html, derby-551-draft1.diff, derby-551-draft1.status,
derby-551-draft2.status, derby-551draft2.diff
> Derby currently doesn't allow CALL statement to be used in a trigger body. It would be
great to allow java stored procedure invocation inside a trigger. Since Derby doesn't have
SQL procedure language, triggers can only execute a single SQL statement. If we allow stored
procedures in triggers, it would be possible to write a trigger that involves more than just
one SQL statement. Functions are currently allowed, but they are read-only.
> I believe it is fairly easy to support this enhancement. Need good amount of testing

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators:
For more information on JIRA, see:

View raw message