[
https://issues.apache.org/jira/browse/DERBY-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13832381#comment-13832381
]
Knut Anders Hatlen commented on DERBY-6420:
-------------------------------------------
Thanks, Kim. The changes look good to me.
In DROP TABLE, though, I think we should keep the sentence that says that
triggers on the table are silently dropped. There is a distinction between a
table used by a trigger and the table on which a trigger is defined. For
example,
CREATE TRIGGER TR AFTER INSERT ON T1 WHEN (EXISTS (SELECT * FROM T2)) INSERT
INTO T3 VALUES 1
is a trigger that is defined on T1 and uses T2 and T3. So dropping T1 will
silently drop TR, whereas dropping T2 or T3 will fail.
As to "fails" vs "generates an error", I don't have any strong preference. Both
sound fine to me. (I see that other DROP statement topics use "an error will
occur" or similar, but I think I prefer your two alternatives.)
Reorganizing DROP VIEW and DROP TABLE sounds useful, if you feel like doing
that while you're at it. (Not required as part of this issue.)
> Clarify how DROP statements work on trigger dependencies
> --------------------------------------------------------
>
> Key: DERBY-6420
> URL: https://issues.apache.org/jira/browse/DERBY-6420
> Project: Derby
> Issue Type: Improvement
> Components: Documentation
> Affects Versions: 10.11.0.0
> Reporter: Knut Anders Hatlen
> Assignee: Kim Haase
> Priority: Minor
> Attachments: DERBY-6420.diff, DERBY-6420.stat, DERBY-6420.zip
>
>
> Some of the DROP statement topics don't mention what happens if an object
> depended on by a trigger gets dropped. We should add this information. The
> behaviour should be more consistent after DERBY-2041.
--
This message was sent by Atlassian JIRA
(v6.1#6144)