From e62f62910d2865d5398636624aec88d0db5546f0 Mon Sep 17 00:00:00 2001 From: Jonathan Ellis Date: Fri, 1 Apr 2011 15:04:52 +0000 Subject: [PATCH] modernize column name quoting git-svn-id: https://svn.apache.org/repos/asf/cassandra/trunk@1087735 13f79535-47bb-0310-9956-ffa450edef68 --- test/system/test_cql.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/test/system/test_cql.py b/test/system/test_cql.py index 208e1e9469..aaaab967f4 100644 --- a/test/system/test_cql.py +++ b/test/system/test_cql.py @@ -68,10 +68,10 @@ def load_sample(dbconn): WITH comparator = ascii AND default_validation = timeuuid; """) dbconn.execute(""" - CREATE COLUMNFAMILY IndexedA (KEY utf8 PRIMARY KEY, 'birthdate' long) + CREATE COLUMNFAMILY IndexedA (KEY utf8 PRIMARY KEY, birthdate long) WITH comparator = ascii AND default_validation = ascii; """) - dbconn.execute("CREATE INDEX ON IndexedA ('birthdate');") + dbconn.execute("CREATE INDEX ON IndexedA (birthdate)") query = "UPDATE StandardString1 SET ? = ?, ? = ? WHERE KEY = ?" dbconn.execute(query, "ca1", "va1", "col", "val", "ka") @@ -441,8 +441,8 @@ class TestCql(ThriftTester): conn = init() conn.execute("USE Keyspace1") conn.execute("CREATE COLUMNFAMILY CreateIndex1 (KEY utf8 PRIMARY KEY)") - conn.execute("CREATE INDEX namedIndex ON CreateIndex1 ('items')") - conn.execute("CREATE INDEX ON CreateIndex1 ('stuff')") + conn.execute("CREATE INDEX namedIndex ON CreateIndex1 (items)") + conn.execute("CREATE INDEX ON CreateIndex1 (stuff)") # TODO: temporary (until this can be done with CQL). ksdef = thrift_client.describe_keyspace("Keyspace1") @@ -455,9 +455,10 @@ class TestCql(ThriftTester): "index_name should be unset, not %s" % stuff.index_name assert stuff.index_type == 0, "missing index" + # already indexed assert_raises(CQLException, conn.execute, - "CREATE INDEX ON CreateIndex1 (\"stuff\")") + "CREATE INDEX ON CreateIndex1 (stuff)") def test_time_uuid(self): "store and retrieve time-based (type 1) uuids"