我正在尝试获取我的列族的列名,这些列名是动态创建的。
我创建了CF
[default@test] CREATE COLUMN FAMILY blog_entry
WITH comparator = TimeUUIDType
AND key_validation_class=UTF8Type
AND default_validation_class = UTF8Type;
[default@test] show schema;
create column family blog_entry
with column_type = 'Standard'
and comparator = 'TimeUUIDType'
and default_validation_class = 'UTF8Type'
and key_validation_class = 'UTF8Type'
and read_repair_chance = 0.1
and dclocal_read_repair_chance = 0.0
and populate_io_cache_on_flush = false
and gc_grace = 864000
and min_compaction_threshold = 4
and max_compaction_threshold = 32
and replicate_on_write = true
and compaction_strategy = 'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy'
and caching = 'KEYS_ONLY'
and compression_options = {'sstable_compression' : 'org.apache.cassandra.io.compress.SnappyCompressor'};我用列名插入了一些数据,但是现在如何查看我的列名呢?
发布于 2014-01-27 20:41:47
您必须逐行查询,才能看到列元数据中没有声明的任何列名。如果要向列元数据中添加列,则需要更改列族定义。卡桑德拉不会自动为你这么做的。
https://stackoverflow.com/questions/21390856
复制相似问题