db-ddlutils-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From to...@apache.org
Subject svn commit: r279065 - in /db/ddlutils/trunk/src/java/org/apache/ddlutils/builder: MSSqlBuilder.java MySqlBuilder.java
Date Tue, 06 Sep 2005 18:52:50 GMT
Author: tomdz
Date: Tue Sep  6 11:52:45 2005
New Revision: 279065

URL: http://svn.apache.org/viewcvs?rev=279065&view=rev
Log:
Fix for DDLUTILS-9

Modified:
    db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MSSqlBuilder.java
    db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MySqlBuilder.java

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MSSqlBuilder.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MSSqlBuilder.java?rev=279065&r1=279064&r2=279065&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MSSqlBuilder.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MSSqlBuilder.java Tue Sep  6 11:52:45
2005
@@ -105,12 +105,16 @@
         print("IDENTITY (1,1) ");
     }
 
-    protected boolean shouldGeneratePrimaryKeys(java.util.List primaryKeyColumns) {
+    /* (non-Javadoc)
+     * @see org.apache.ddlutils.builder.SqlBuilder#shouldGeneratePrimaryKeys(org.apache.ddlutils.model.Column[])
+     */
+    protected boolean shouldGeneratePrimaryKeys(Column[] primaryKeyColumns)
+    {
         /*
          * requires primary key indication for autoincrement key columns
          * I'm not sure why the default skips the pk statement if all are identity
          */
-        return primaryKeyColumns.size() > 0;
+        return primaryKeyColumns.length > 0;
     }
 
     public void writeExternalIndexDropStmt(Table table, Index index) throws IOException

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MySqlBuilder.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MySqlBuilder.java?rev=279065&r1=279064&r2=279065&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MySqlBuilder.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/builder/MySqlBuilder.java Tue Sep  6 11:52:45
2005
@@ -18,7 +18,6 @@
 
 import java.io.IOException;
 import java.sql.Types;
-import java.util.List;
 
 import org.apache.ddlutils.PlatformInfo;
 import org.apache.ddlutils.model.Column;
@@ -91,9 +90,9 @@
     }
 
     /* (non-Javadoc)
-     * @see org.apache.ddlutils.builder.SqlBuilder#shouldGeneratePrimaryKeys(List)
+     * @see org.apache.ddlutils.builder.SqlBuilder#shouldGeneratePrimaryKeys(org.apache.ddlutils.model.Column[])
      */
-    protected boolean shouldGeneratePrimaryKeys(List primaryKeyColumns)
+    protected boolean shouldGeneratePrimaryKeys(Column[] primaryKeyColumns)
     {
         /*
          * mySQL requires primary key indication for autoincrement key columns



Mime
View raw message