I figured that if i execute batch in Cassandra(using java driver) no matter where the update/insert/delete placed, it always execute in the order of, update, insert, delete. Like the code below, after i run it, the table is empty. How can i force cassandra to execute to my order?
PreparedStatement trybach = MyConnection
.getSession()
.prepare(
"BEGIN BATCH USING TIMESTAMP"
+ " INSERT INTO transaction_test.users(email,age,firstname,lastname) VALUES ('try',18,'fname','lname');"
+ " DELETE FROM transaction_test.users WHERE email ='try';"
+ " UPDATE transaction_test.users SET age= 13 WHERE email= 'try';"
+
"APPLY BATCH");
MyConnection.getSession().execute(trybach.bind());