Is there a way automatically update some tuples based on time.
I have a field that I would like to increment every week from the time stored for that particular row.
Say I have two tuples with date and count fields:
2000-01-02 10
2000-01-03 1
Is it possible to automatically increment the count field every week from the stored date?
So that the first row is incremented on 2000-01-09 and the second row is incremented on 2000-01-10 and this would be done weekly.
Or in general can I update something automatically based on some time gone by?
Thank you.
You could store an extra field:
next_increment_date.Then you update regularly (say, once per hour or day… or however often makes sense):