Reputation: 3191
I'm having a weird behavior with Cassandra. Whenever I try finding some rows by id, it returns me null (either by cqlsh console or clients), but the register exists if I find by another field.
For example:
My table schema:
CREATE TABLE IF NOT EXISTS user_aggregation_new.user_aggregation_new (
userid timeuuid PRIMARY KEY,
fullname text,
birthdate text,
password text,
mobile text,
address frozen <address>,
thumbs map<text, text>,
driverlicense frozen <driverlicense>,
cpf text,
facebookid text,
membershipsince timestamp,
rating double,
email text,
status text,
facebookemail boolean,
bankaccount list<frozen <bankaccount>>,
dateupdated timestamp,
version bigint
);
Cassandra version: 3.7
Why is this happening ?
Upvotes: 1
Views: 117
Reputation: 1044
You have two options :
Run nodetool repair on each node to improve data consistency
Increase your client consistency level. In cqlsh, run the command CONSISTENCY with value QUORUM or ALL
Then retry and get back to us if it is still not working.
Upvotes: 2