P.K.
cassandra-cli的基本操作
查看帮助文档 help;
查看所有的键空间 show keyspaces;
创建键空间 create keyspace testkeyspace;
进入创建好的名为root的键空间 use testkeyspace;
创建列族users并指定UTF8排序属性 create column family users with comparator = UTF8Type;
插入数据 set users[utf8('zhangsan')][utf8('address')][utf8('company')]=utf8('shanghai');
获取相应列的数据 get users[utf8('zhangsan')]
设置超级列 create column family users with comparator = UTF8Type and column_type=Super
CQL数据定义语句
1.
2.
3.