You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@cassandra.apache.org by Ken Hancock <ke...@schange.com> on 2015/01/23 17:28:13 UTC
BytesType and UTF8Type
I have some thrift column families that were created with BytesType. All
the data written to the keys/columns/values were simple string.
In cassandra-cli, I can "correct" these to UTF8Type (I believe both
UTF8Type and BytesType are serialized similarly?) but I can't convert these
blobs to text via CQL.
(1) if my strings are all ascii, is it safe to "correct" the validation
classes?
(2) is the cql restriction merely a safety mechanism that cassandra-cli is
lacking?
Thanks,
Ken
Re: BytesType and UTF8Type
Posted by Sylvain Lebresne <sy...@datastax.com>.
On Fri, Jan 23, 2015 at 5:28 PM, Ken Hancock <ke...@schange.com>
wrote:
>
> I have some thrift column families that were created with BytesType. All
> the data written to the keys/columns/values were simple string.
>
> In cassandra-cli, I can "correct" these to UTF8Type (I believe both
> UTF8Type and BytesType are serialized similarly?) but I can't convert these
> blobs to text via CQL.
>
> (1) if my strings are all ascii, is it safe to "correct" the validation
> classes?
>
It is, provided your initial assumption ("my strings are all ascii") is
actually true.
> (2) is the cql restriction merely a safety mechanism that cassandra-cli is
> lacking?
>
It is.
--
Sylvain
>