cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tylerho...@apache.org
Subject [2/2] cassandra git commit: Merge branch 'cassandra-2.0' into cassandra-2.1
Date Fri, 21 Nov 2014 19:26:09 GMT
Merge branch 'cassandra-2.0' into cassandra-2.1

Conflicts:
	src/java/org/apache/cassandra/cql3/statements/UpdateStatement.java


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/6826888b
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/6826888b
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/6826888b

Branch: refs/heads/cassandra-2.1
Commit: 6826888be8604b3336e994c18f4c0e51f393d071
Parents: 705e5e4 025b406
Author: Tyler Hobbs <tyler@datastax.com>
Authored: Fri Nov 21 13:25:41 2014 -0600
Committer: Tyler Hobbs <tyler@datastax.com>
Committed: Fri Nov 21 13:25:41 2014 -0600

----------------------------------------------------------------------
 .../cassandra/cql3/statements/UpdateStatement.java      | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/6826888b/src/java/org/apache/cassandra/cql3/statements/UpdateStatement.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/cql3/statements/UpdateStatement.java
index b11173a,e2da251..2c87173
--- a/src/java/org/apache/cassandra/cql3/statements/UpdateStatement.java
+++ b/src/java/org/apache/cassandra/cql3/statements/UpdateStatement.java
@@@ -136,13 -138,17 +136,17 @@@ public class UpdateStatement extends Mo
  
              for (int i = 0; i < columnNames.size(); i++)
              {
-                 ColumnDefinition def = cfm.getColumnDefinition(columnNames.get(i).prepare(cfm));
 -                ColumnIdentifier id = columnNames.get(i).prepare(cfDef.cfm);
 -                CFDefinition.Name name = cfDef.get(id);
 -                if (name == null)
++                ColumnIdentifier id = columnNames.get(i).prepare(cfm);
++                ColumnDefinition def = cfm.getColumnDefinition(id);
 +                if (def == null)
-                     throw new InvalidRequestException(String.format("Unknown identifier
%s", columnNames.get(i)));
+                     throw new InvalidRequestException(String.format("Unknown identifier
%s", id));
  
                  for (int j = 0; j < i; j++)
-                     if (def.name.equals(columnNames.get(j)))
-                         throw new InvalidRequestException(String.format("Multiple definitions
found for column %s", def.name));
+                 {
 -                    ColumnIdentifier otherId = columnNames.get(j).prepare(cfDef.cfm);
++                    ColumnIdentifier otherId = columnNames.get(j).prepare(cfm);
+                     if (id.equals(otherId))
+                         throw new InvalidRequestException(String.format("Multiple definitions
found for column %s", id));
+                 }
  
                  Term.Raw value = columnValues.get(i);
  


Mime
View raw message