[ 
https://issues.apache.org/jira/browse/CASSANDRA-13694?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Brandon Williams updated CASSANDRA-13694:
-----------------------------------------
    Resolution: Not A Problem
        Status: Resolved  (was: Open)

I'm not sure where this was fixed but it no longer is an issue on 3.11:

{noformat}
[
  {
    "partition" : {
      "key" : [ "1234", "TEST EVENT" ],
      "position" : 0
    },
    "rows" : [
      {
        "type" : "row",
        "position" : 38,
        "clustering" : [ "2021-06-29 15:40:06.784Z" ],
        "liveness_info" : { "tstamp" : "2021-06-29T15:40:06.773016Z" },
        "cells" : [
          { "name" : "ack_time", "value" : "2021-06-29 15:40:06.785Z" }
        ]
      }
    ]
  }
{noformat}

> sstabledump does not show full precision of timestamp columns
> -------------------------------------------------------------
>
>                 Key: CASSANDRA-13694
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-13694
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Legacy/Tools
>         Environment: Ubuntu 16.04 LTS
>            Reporter: Tim Reeves
>            Assignee: Varun Barala
>            Priority: Normal
>              Labels: patch-available
>             Fix For: 3.11.x
>
>         Attachments: CASSANDRA-13694-after-review.patch, CASSANDRA-13694.patch
>
>
> Create a table:
> CREATE TABLE test_table (
>     unit_no bigint,
>     event_code text,
>     active_time timestamp,
>     ack_time timestamp,
>     PRIMARY KEY ((unit_no, event_code), active_time)
> ) WITH CLUSTERING ORDER BY (active_time DESC)
> Insert a row:
> INSERT INTO test_table (unit_no, event_code, active_time, ack_time)
>                   VALUES (1234, 'TEST EVENT', toTimestamp(now()), 
> toTimestamp(now()));
> Verify that it is in the database with a full timestamp:
> cqlsh:pentaho> select * from test_table;
>  unit_no | event_code | active_time                     | ack_time
> ---------+------------+---------------------------------+---------------------------------
>     1234 | TEST EVENT | 2017-07-14 14:52:39.919000+0000 | 2017-07-14 
> 14:52:39.919000+0000
> (1 rows)
> Write file:
> nodetool flush
> nodetool compact pentaho
> Use sstabledump:
> treeves@ubuntu:~$ sstabledump 
> /var/lib/cassandra/data/pentaho/test_table-99ba228068a311e7ac30953b79ac2c3e/mb-2-big-Data.db
> [
>   {
>     "partition" : {
>       "key" : [ "1234", "TEST EVENT" ],
>       "position" : 0
>     },
>     "rows" : [
>       {
>         "type" : "row",
>         "position" : 38,
>         "clustering" : [ "2017-07-14 15:52+0100" ],
>         "liveness_info" : { "tstamp" : "2017-07-14T14:52:39.888701Z" },
>         "cells" : [
>           { "name" : "ack_time", "value" : "2017-07-14 15:52+0100" }
>         ]
>       }
>     ]
>   }
> ]
> treeves@ubuntu:~$ 
> The timestamp in the cluster key, and the regular column, are both truncated 
> to the minute.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org
For additional commands, e-mail: commits-h...@cassandra.apache.org

Reply via email to