Hi, According to documentation at
https://docs.datastax.com/en/cql/3.3/cql/cql_reference/cql_data_types_c.html#cql_data_types_c__cql_data_type_compatibility
we should not be able to change the column type from ascii to text. I have had
a mix experience with conversion between data types on different versions of
Cassandra. For example, given the following table definition: CREATE TABLE
changelog ( sequence int, description ascii, createdby ascii,
executedon timestamp, PRIMARY KEY (sequence, description) ) Attempting
change the data type for column 'createdby' with following CQL alter
table changelog alter createdby TYPE text; gives the behaviour outlined below
depending on the version of Cassandra: With [cqlsh 5.0.1 | Cassandra 3.0.16 |
CQL spec 3.4.0 | Native protocol v4] InvalidRequest: Error from server:
code=2200 [Invalid query] message="Altering of types is not allowed" (Expected,
per documentation) With [cqlsh 5.0.1 | Cassandra 3.9 | CQL spec 3.4.2 | Native
protocol v4] Query succeeds and change the column type to 'text' (as verified
by running describe changelog and also inserting data with non-ascii chars into
the column) With Cassandra 3.11.2 InvalidRequest: Error from server: code=2200
[Invalid query] message="Altering of types is not allowed" (Expected, per
documentation) Can anyone please explain why it works on 3.9 and not on others?
Thanks! Thira