Project:
View Revisions: Issue #16832 | [ All Revisions ] [ Back to Issue ] | ||
Summary | 0016832: A trigger condition in c_orderline has been added and can cause problems in special conditions | ||
Revision | 2011-04-15 16:43 by dalsasua | ||
Description | This piece of code has been added to src-db/database/model/triggers/C_ORDLINE_CHK_RESTRICTIONS_TRG.xml: IF(UPDATING OR INSERTING) THEN IF (:NEW.C_BPARTNER_ID IS NOT NULL AND :NEW.C_BPARTNER_LOCATION_ID IS NULL) THEN RAISE_APPLICATION_ERROR(-20000, '@LocationNotNullConstraint@'); END IF; END IF; This piece of code is trying to simulate the old behavior when the line is not a discount. This piece of code is wrong because in some special conditions the user can not insert lines or modify existing lines where this field is null. The original bug is solved without this change in the trigger. |
||
Revision | 2011-04-15 16:43 by dalsasua | ||
Description | This piece of code has been added to src-db/database/model/triggers/C_ORDLINE_CHK_RESTRICTIONS_TRG.xml: IF(UPDATING OR INSERTING) THEN IF (:NEW.C_BPARTNER_ID IS NOT NULL AND :NEW.C_BPARTNER_LOCATION_ID IS NULL) THEN RAISE_APPLICATION_ERROR(-20000, '@LocationNotNullConstraint@'); END IF; END IF; This piece of code is trying to simulate the old behavior when the line is not a discount. This piece of code is wrong because in some special conditions the user can not insert lines or modify existing lines where this field is null. The original bug is solved without this change in the trigger. |
Copyright © 2000 - 2009 MantisBT Group |