2
我知道cassandra可以,但Astyanax呢?它是否會在值中單引號? THX確實Astyanax支持cql 3編寫語句嗎?
我知道cassandra可以,但Astyanax呢?它是否會在值中單引號? THX確實Astyanax支持cql 3編寫語句嗎?
是它,
這裏你可以看到一個例子https://github.com/Netflix/astyanax/wiki/Cql-and-cql3
final String INSERT_STATEMENT = "INSERT INTO employees (empID, deptID, first_name, last_name) VALUES (?, ?, ?, ?);";
result = keyspace
.prepareQuery(CQL3_CF)
.withCql(INSERT_STATEMENT)
.asPreparedStatement()
.withIntegerValue(222)
.withIntegerValue(333)
.withStringValue("Eric")
.withStringValue("Cartman")
.execute();