Julien LEFORT wrote:
Hi,
I would like to implement a log table with a finite dimension, for exemple a
table with 500 records, and when the last record is set in the table I would
like to come back at the first tuplet and write over the previous value
recorded. I think it's the way SQLite journal is implmented.
Is there any way to declare this table with these properties included, so I
don't have to add code to do this function?
Thanks
A guy on this end had a suggestion that I kicked myself for not
thinking of earlier: Use a simple numeric ID that you mod by the number
of records you want, automatically overwriting the oldest record when a
new one comes along.. I may have to put together a smallish trigger to
keep the IDs in range, perhaps a manual implementation of a simple
sequence to pull a value from, then use that as the record ID.
-P
- Re: [sqlite] ring buffer table Paul Bohme
-