Author: snoopdave
Date: Sun Jul 20 20:52:21 2014
New Revision: 1612161

URL: http://svn.apache.org/r1612161
Log:
Fix for the MySQL table rename case, unsure if sp_rename is the right syntax 
for MS SQL Server.

Modified:
    roller/trunk/app/src/main/resources/sql/macros.vm

Modified: roller/trunk/app/src/main/resources/sql/macros.vm
URL: 
http://svn.apache.org/viewvc/roller/trunk/app/src/main/resources/sql/macros.vm?rev=1612161&r1=1612160&r2=1612161&view=diff
==============================================================================
--- roller/trunk/app/src/main/resources/sql/macros.vm (original)
+++ roller/trunk/app/src/main/resources/sql/macros.vm Sun Jul 20 20:52:21 2014
@@ -85,12 +85,11 @@ Define non-null column with default valu
 #**
 Rename a table.
 For Derby, will not work if there is a view or foreign key that references the 
table.
-MySQL requires sp_rename command; unsure if works.
 **#
 #macro(renameTable $oldTableName $newTableName)
 #if ($db.DBTYPE == 'POSTGRESQL' || $db.DBTYPE == 'HSQLDB')
 alter table $oldTableName rename to $newTableName;
-#elseif ($db.DBTYPE == 'MYSQL')
+#elseif ($db.DBTYPE == 'MSSQL')
 sp_rename '$oldTableName', '$newTableName';
 #else
 rename table $oldTableName TO $newTableName;


Reply via email to