[
https://issues.apache.org/jira/browse/CASSANDRA-14070?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16272199#comment-16272199
]
Himani Arora commented on CASSANDRA-14070:
------------------------------------------
Hi Kurt,
I am trying to implement a trigger on a Cassandra table to fetch values of all
columns. In order to get clustering key values, I could find the method in
Cassandra's code on GitHub.
public default String toCQLString(TableMetadata metadata)
{
StringBuilder sb = new StringBuilder();
for (int i = 0; i < size(); i++)
{
ColumnMetadata c = metadata.clusteringColumns().get(i);
sb.append(i == 0 ? "" : ", ").append(c.type.getString(get(i)));
}
return sb.toString();
}
But as you can see it is providing me a concatenated string of all the
clustering key values but it would be better if a list is provided instead of a
concatenated string.
> Add new method for returning list of primary/clustering key values
> ------------------------------------------------------------------
>
> Key: CASSANDRA-14070
> URL: https://issues.apache.org/jira/browse/CASSANDRA-14070
> Project: Cassandra
> Issue Type: Improvement
> Components: CQL
> Reporter: Himani Arora
> Priority: Minor
> Fix For: 4.x
>
>
> Add a method to return a list of primary/clustering key values so that it
> will be easier to process data. Currently, we are getting a string
> concatenated with either colon (: ) or comma (,) which makes it quite
> difficult to fetch one single key value.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]