It seems that Cassabdra behaves differently when inserting data to (existing row in) a table while not/using JSON.
Here is an example:
- "INSERT INTO " + tableName + "(" + fields + ") VALUES (" + values + ")"
- "INSERT INTO " + tableName + " JSON '" + json + "'"
In example #1, the insert acts like an upsert- updating only the mentioned fields and keeping the rest of the fields as they were before the insert.
In example #2, the insert acts almost like a classic insert - overwriting the old row with the new one.
What's the best way using JSON query (like example #2) which will act as the query in example #1?
Thanks ahead,
Eyal