Introduction to Cassandra Query Language
Cassandra Query Language (CQL) is a query language for the Cassandra database.
Cassandra 2.1 features¶
- Nested user-defined types
- Improved counter columns that maintain the correct count when Cassandra replays the commit log
- Configurable counter cache
- Support for indexes on collections, including using map keys to filter query results
- Timestamps precise to the millisecond
- The new tuple type that holds fixed-length sets of typed positional fields
Cassandra 2.0.x features¶
- Lightweight transactions using the IF keyword in INSERT and UPDATE statements.
- Prevention of application errors by performing conditional tests for the existence of a table, keyspace, or index.
- Initial support for triggers that fire events executed in or out of a database cluster.
- The ALTER TABLE DROP command, which had been removed in the earlier release.
- Column aliases, similar to aliases in RDBMS SQL, in a SELECT statement.
- Indexing of the part, partition key or clustering columns, portion of a compound primary key.
DataStax drivers support Cassandra 2.0.
CQL for Cassandra 2.0 deprecated super columns. Cassandra continues to support apps that query super columns, translating super columns on the fly into CQL constructs and results.