db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rhille...@apache.org
Subject svn commit: r1476235 - in /db/derby/code/trunk/java/engine/org/apache/derby: iapi/sql/dictionary/TriggerDescriptor.java impl/sql/execute/AlterTableConstantAction.java
Date Fri, 26 Apr 2013 14:50:52 GMT
Author: rhillegas
Date: Fri Apr 26 14:50:50 2013
New Revision: 1476235

URL: http://svn.apache.org/r1476235
Log:
DERBY-6202: Fix bug involving upgrade, triggers, and dropped columns.

Modified:
    db/derby/code/trunk/java/engine/org/apache/derby/iapi/sql/dictionary/TriggerDescriptor.java
    db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/execute/AlterTableConstantAction.java

Modified: db/derby/code/trunk/java/engine/org/apache/derby/iapi/sql/dictionary/TriggerDescriptor.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/iapi/sql/dictionary/TriggerDescriptor.java?rev=1476235&r1=1476234&r2=1476235&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/iapi/sql/dictionary/TriggerDescriptor.java
(original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/iapi/sql/dictionary/TriggerDescriptor.java
Fri Apr 26 14:50:50 2013
@@ -465,6 +465,12 @@ public class TriggerDescriptor extends T
 		return ArrayUtil.copy( referencedCols );
 	}
 
+    /** Update the array of referenced columns */
+    public  void    setReferencedCols( int[] newCols )
+    {
+        referencedCols = ArrayUtil.copy( newCols );
+    }
+
 	/**
 	 * Get the referenced column array for the trigger action columns.
 	 *

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/execute/AlterTableConstantAction.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/execute/AlterTableConstantAction.java?rev=1476235&r1=1476234&r2=1476235&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/execute/AlterTableConstantAction.java
(original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/execute/AlterTableConstantAction.java
Fri Apr 26 14:50:50 2013
@@ -1484,6 +1484,7 @@ class AlterTableConstantAction extends D
 						if (referencedCols[j] > droppedColumnPosition)
 							referencedCols[j]--;
 					}
+                    trd.setReferencedCols( referencedCols );
 					dd.addDescriptor(trd, sd,
 									 DataDictionary.SYSTRIGGERS_CATALOG_NUM,
 									 false, tc);



Mime
View raw message