Consider this scenario in a SQL database:

UPDATE foo SET x = 1 WHERE key = 'asdf';

Now, "simultaneously," two clients run

UPDATE foo SET x = 2 WHERE key = 'asdf';
and
SELECT * FROM foo WHERE x = 1;

Either you get back row asdf, or you don't.  Either is valid.  Same
thing happens with Cassandra indexes.

On Fri, Sep 9, 2011 at 10:41 AM,  <alta...@ceid.upatras.gr> wrote:
> I see that Cassandra updates secondary indices as soon as a value of the
> indexed column is updated. This can happen, for example, during a select
> query with a condition on a secondary index. Does Cassandra perform no
> checking or locking? Will the result of this select, with old and new
> values, be returned as is? Am I missing some reason why this isn't a
> problem?
>
> Alexander
>



-- 
Jonathan Ellis
Project Chair, Apache Cassandra
co-founder of DataStax, the source for professional Cassandra support
http://www.datastax.com

Reply via email to