[FOLLOW UP QUESTION TO #6319]
Can we use set datatype instead of json
GOT QUESTIONS from the Workshop? You're in the right place! Post a question here and we'll get you answers.
Can we use set datatype instead of json
The CQL set
collection type is a list of unique values of another CQL data type (e.g. text
, int
) or a user-defined type (UDT). For example, you can have a column in a table which contains the names of friends like this:
friends set<text>
It's difficult to answer your question without additional background information but it doesn't make sense to store JSON documents into a CQL collection unless your JSON looks something like:
{ "friends": [ 'Tom', 'Dick', 'Harry' ] }
If you provide an example of your data in JSON format, I'd be happy to review it and give you a better response. Cheers!
6 People are following this question.
DataStax Enterprise is powered by the best distribution of Apache Cassandra ™
© 2022 DataStax, Titan, and TitanDB are registered trademarks of DataStax, Inc. and its subsidiaries in the United States and/or other countries.
Apache, Apache Cassandra, Cassandra, Apache Tomcat, Tomcat, Apache Lucene, Lucene, Apache Solr, Apache Hadoop, Hadoop, Apache Spark, Spark, Apache TinkerPop, TinkerPop, Apache Kafka and Kafka are either registered trademarks or trademarks of the Apache Software Foundation or its subsidiaries in Canada, the United States and/or other countries.
Privacy Policy Terms of Use