Cassandra Snap Pack

Cassandra Snap Pack

On this Page

Overview

You can use the Cassandra Snap Pack to work with data in Apache Cassandra. 

Use Snaps in this Snap Pack to:

  • Execute a Cassandra Select.

  • Execute a Cassandra statement or query.

Supported Versions

This Snap Pack is tested against Cassandra versions 1.2, 2.0, and 3.0.

Known Issues

Snaps in this Snap Pack display an exception (raised by the JDBC driver) when you query a map column that has a timestamp as the key.

Example

  1. Create a table containing a map whose key is a timestamp:
    CREATE COLUMNFAMILY t (userid text PRIMARY KEY, todo map<timestamp, text>);

  2. Insert values into the newly-created table.
    INSERT INTO t (userid, todo) VALUES ('a', {'2013-09-22T12:01:00.000+0000': 'text'});

  3. Once the insert operation succeeds, query the map column:
    SELECT userid, todo FROM t;

    The Snap displays the following exception:

    com.datastax.driver.core.exceptions.CodecNotFoundException:
    Codec not found for requested operation: [timestamp <-> java.sql.Timestamp]

Behavior change

The jOOQ upgrade for Cassandra Snap Pack done as part of 436patches25597 resulted in the following behavior changes:

  • Previously, when TTL (time to live) was queried using a Select statement without specifying it during data insertion or update, the Cassandra Snaps would display '0'. Now, they return 'null' in such cases.

  • Previously, the null values were stored as ‘0' in the INT datatype columns, now they are stored as 'null’.


See Also

Snap Pack History