![Adam Holmberg](/assets/img/avatar_default.png)
Hoping to avoid confusion on statement initializers by removing the signature and dropping the position of the abstract class. PYTHON-219
1.5 KiB
1.5 KiB
cassandra.query
- Prepared Statements, Batch Statements, Tracing, and Row Factories
cassandra.query
tuple_factory
named_tuple_factory
dict_factory
ordered_dict_factory
SimpleStatement
PreparedStatement ()
BoundStatement
Statement ()
UNSET_VALUE
BatchStatement (batch_type=BatchType.LOGGED, retry_policy=None, consistency_level=None)
BatchType ()
LOGGED
UNLOGGED
COUNTER
cassandra.query.ValueSequence
A wrapper class that is used to specify that a sequence of values
should be treated as a CQL list of values instead of a single column
collection when used as part of the parameters argument for .Session.execute()
.
This is typically needed when supplying a list of keys to select. For example:
>>> my_user_ids = ('alice', 'bob', 'charles')
>>> query = "SELECT * FROM users WHERE user_id IN %s"
>>> session.execute(query, parameters=[ValueSequence(my_user_ids)])
QueryTrace ()
TraceEvent ()
TraceUnavailable