You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@cassandra.apache.org by Furkan Cifci <fu...@gmail.com> on 2020/03/02 11:29:30 UTC

Deleting data from future

Greetings,
In our C* cluster, one node lost time sync and it went to future(16 Mar
2020) for a while.
After fixing timesync, we couldnt update or delete records which were
inserted while node's system time was from the future.
Inspecting sstables, we found that  timestamp(TS field value) of these
records was 1584349956844022,  Monday, 16 March 2020 09:12:36.844.
We neither delete these records nor truncate table.
Is there anyway to manipulate records inside sstable manually?

Re: Deleting data from future

Posted by Erick Ramirez <er...@datastax.com>.
>
> Inspecting sstables, we found that  timestamp(TS field value) of these
> records was 1584349956844022,  Monday, 16 March 2020 09:12:36.844.
> We neither delete these records nor truncate table.
> Is there anyway to manipulate records inside sstable manually?
>

Not really unless you plan to write code to do it which can get messy.
Unfortunately even if you delete the partitions/rows with a "future"
timestamp (i.e. greater than 1584349956844022), it still won't take effect
until after that point in time on March 16. If that's good enough, then
follow Jon's recommendation. Cheers!

Re: Deleting data from future

Posted by Jon Haddad <jo...@jonhaddad.com>.
You can issue a delete using a future timestamp.

http://cassandra.apache.org/doc/latest/cql/dml.html#grammar-token-update-parameter

Look for USING TIMESTAMP.

Jon

On Mon, Mar 2, 2020, 3:28 AM Furkan Cifci <fu...@gmail.com> wrote:

> Greetings,
> In our C* cluster, one node lost time sync and it went to future(16 Mar
> 2020) for a while.
> After fixing timesync, we couldnt update or delete records which were
> inserted while node's system time was from the future.
> Inspecting sstables, we found that  timestamp(TS field value) of these
> records was 1584349956844022,  Monday, 16 March 2020 09:12:36.844.
> We neither delete these records nor truncate table.
> Is there anyway to manipulate records inside sstable manually?
>
>
>
>
>