You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by sl...@apache.org on 2015/08/16 12:16:39 UTC

cassandra git commit: Fix typo in CREATE TABLE error message

Repository: cassandra
Updated Branches:
  refs/heads/cassandra-2.2 c645b1193 -> 0f287c46f


Fix typo in CREATE TABLE error message

patch by sehrope; reviewed by slebresne for CASSANDRA-10087


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

Branch: refs/heads/cassandra-2.2
Commit: 0f287c46fc87032c82bd53be11a13f2780b35593
Parents: c645b11
Author: Sylvain Lebresne <sy...@datastax.com>
Authored: Sun Aug 16 12:15:20 2015 +0200
Committer: Sylvain Lebresne <sy...@datastax.com>
Committed: Sun Aug 16 12:15:20 2015 +0200

----------------------------------------------------------------------
 .../org/apache/cassandra/cql3/statements/CreateTableStatement.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/0f287c46/src/java/org/apache/cassandra/cql3/statements/CreateTableStatement.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/cql3/statements/CreateTableStatement.java b/src/java/org/apache/cassandra/cql3/statements/CreateTableStatement.java
index b3591a2..7810a8a 100644
--- a/src/java/org/apache/cassandra/cql3/statements/CreateTableStatement.java
+++ b/src/java/org/apache/cassandra/cql3/statements/CreateTableStatement.java
@@ -221,7 +221,7 @@ public class CreateTableStatement extends SchemaAlteringStatement
         {
             // Column family name
             if (!columnFamily().matches("\\w+"))
-                throw new InvalidRequestException(String.format("\"%s\" is not a valid table name (must be alphanumeric character only: [0-9A-Za-z]+)", columnFamily()));
+                throw new InvalidRequestException(String.format("\"%s\" is not a valid table name (must be alphanumeric character or underscore only: [a-zA-Z_0-9]+)", columnFamily()));
             if (columnFamily().length() > Schema.NAME_LENGTH)
                 throw new InvalidRequestException(String.format("Table names shouldn't be more than %s characters long (got \"%s\")", Schema.NAME_LENGTH, columnFamily()));