You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Kurt Greaves (JIRA)" <ji...@apache.org> on 2016/11/23 02:27:58 UTC

[jira] [Commented] (CASSANDRA-12936) Unique Small Numeric Code for each row in Cassandra

    [ https://issues.apache.org/jira/browse/CASSANDRA-12936?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15688650#comment-15688650 ] 

Kurt Greaves commented on CASSANDRA-12936:
------------------------------------------

This would give really bad performance as we'd need to read before every new row is written to ensure we don't write the same ID for multiple rows or at least have some centralised tracking/agreement of the ID, which is going to be expensive/not really fitting to Cassandra.
It seems to me this would be much better implemented on the application side, is there any reason you can't have another ID field paired with the UUID?

> Unique Small Numeric Code for each row in Cassandra
> ---------------------------------------------------
>
>                 Key: CASSANDRA-12936
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-12936
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: CQL
>         Environment: All Platforms
>            Reporter: Aakash
>
> We have a requirement where we need to maintain a unique number or code (easy to remember) for the Publishers and Offerings that we will create for them. This should be auto created may not be sequential (though we prefer the same).
> We have tables for publishers with their details name, address, billing info etc.
> and similarly for offerings too.
> This generated code will be used in reports and billing too, and also in request params.
> We do understand we have a unique UUID datatype, but it's too big to be remembered, and to be used to identify unique identities.
> What we need is a very basic feature used extensively in all RDBMS, but in Cassandra there no way to implement similar functionality.
> This is something that i guess would be needed by lot of people making a switch to Cassandra - a way to generate small unique number for each entry/row in a table
> Regards, 
> Aakash



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)