empire-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From doeb...@apache.org
Subject svn commit: r1185554 - in /incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db: DBTable.java DBView.java
Date Tue, 18 Oct 2011 10:34:36 GMT
Author: doebele
Date: Tue Oct 18 10:34:36 2011
New Revision: 1185554

URL: http://svn.apache.org/viewvc?rev=1185554&view=rev
Log:
EMPIREDB-118

Modified:
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBTable.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBView.java

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBTable.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBTable.java?rev=1185554&r1=1185553&r2=1185554&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBTable.java (original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBTable.java Tue
Oct 18 10:34:36 2011
@@ -183,7 +183,7 @@ public class DBTable extends DBRowSet im
     { // find column by name
         if (column==null || column.getRowSet()!=this)
             throw new InvalidArgumentException("column", column);
-        if (columns.contains(column) == true)
+        if (getColumn(column.getName())!=null)
             throw new ItemExistsException(column.getName());
         // add now
         columns.add(column);

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBView.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBView.java?rev=1185554&r1=1185553&r2=1185554&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBView.java (original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/DBView.java Tue
Oct 18 10:34:36 2011
@@ -289,7 +289,7 @@ public abstract class DBView extends DBR
     { // find column by name
         if (col == null || col.getRowSet() != this)
             throw new InvalidArgumentException("col", col);
-        if (columns.contains(col) == true)
+        if (getColumn(col.getName())!=null)
             throw new ItemExistsException(col.getName());
         // add now
         columns.add(col);



Mime
View raw message