Author: tv
Date: Fri Apr  8 08:09:38 2016
New Revision: 1738219

URL: http://svn.apache.org/viewvc?rev=1738219&view=rev
Log:
Fix foreign key references for Derby

Modified:
    
db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.groovy
    
db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.vm

Modified: 
db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.groovy
URL: 
http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.groovy?rev=1738219&r1=1738218&r2=1738219&view=diff
==============================================================================
--- 
db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.groovy
 (original)
+++ 
db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.groovy
 Fri Apr  8 08:09:38 2016
@@ -30,6 +30,11 @@ if (foreignKey.onUpdate == "setnull")
     result += """
     ON UPDATE SET NULL"""
 } 
+else if (foreignKey.onUpdate == "none") 
+{ 
+    result += """
+    ON UPDATE NO ACTION"""
+}
 else if (foreignKey.onUpdate) 
 { 
     result += """
@@ -41,6 +46,12 @@ if (foreignKey.onDelete == "setnull")
 
     ON DELETE SET NULL"""
 } 
+else if (foreignKey.onDelete == "none") 
+{ 
+    result += """
+
+    ON DELETE NO ACTION"""
+}
 else if (foreignKey.onDelete) 
 { 
     result += """

Modified: 
db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.vm
URL: 
http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.vm?rev=1738219&r1=1738218&r2=1738219&view=diff
==============================================================================
--- 
db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.vm
 (original)
+++ 
db/torque/torque4/trunk/torque-templates/src/main/resources/org/apache/torque/templates/sql/templates/ddl/derby/foreignKey.vm
 Fri Apr  8 08:09:38 2016
@@ -21,6 +21,9 @@ ALTER TABLE $torqueGen.getParent().getAt
 #if ($onUpdate == "setnull")
 
     ON UPDATE SET NULL##
+#elseif ($onUpdate == "none")
+
+    ON UPDATE NO ACTION##
 #elseif ($onUpdate)
 
     ON UPDATE ${onUpdate.toUpperCase()}##
@@ -28,6 +31,9 @@ ALTER TABLE $torqueGen.getParent().getAt
 #if ($onDelete == "setnull")
 
     ON DELETE SET NULL##
+#elseif ($onDelete == "none")
+
+    ON DELETE NO ACTION##
 #elseif ($onDelete)
 
     ON DELETE ${onDelete.toUpperCase()}##



---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscr...@db.apache.org
For additional commands, e-mail: torque-dev-h...@db.apache.org

Reply via email to