Fork me on GitHub
Toyam Cox21:10:05

I want to delete a transaction at a point in the future. I also want to be able to cancel that deletion should I wish. Is there a good way to do this?

Toyam Cox21:10:03

I don't think I can use a :crux.tx/delete for this

Toyam Cox21:10:13

Really what I kind of want is a :crux.tx/match-and-delete

Toyam Cox21:10:11

since I can adjust a key in the document and make the deletion no longer execute.


A delete with a future timestamp doesn't execute in the future, it is applied to the timeline immediately. Which is the same as all other tx operations. I think what you should consider instead is to make the if-else logic happen at query time and model your own "delete" concept as a new entity or attribute. Just to be sure though, can you say more about the use-case?

Toyam Cox10:10:10

With this new knowledge it seems what I wanted was [[:crux.tx/delete :mykey] [:crux.tx/put mydoc (now) (new-deletion-time)]]

🙂 3