TREND FILE RECORDING MANAGMENT

2020-10-15
2020-10-20
  • jeromebunel

    jeromebunel - 2020-10-15

    Hello to all.

    My question concerns the management of the trend curve files recording.

    1) no limit
    2) limited in file size
    3) limited in number of registrations.

    I thought that once the limit is reached (file size or number of recordings), the recording will continue as a circular buffer. That is, the oldest data is replaced by the most recent data.
    But it seems not. I notice that the SQLlite file is no longer refreshed.

    How do you deal with this problem?

    Is it possible to operate as a circular buffer

    Thank you

    JerΓ΄me Bunel.

     
  • jeromebunel

    jeromebunel - 2020-10-16

    Hello.
    I'm surprised no one reacted to my previous post.

    Maybe I explained badly.

    So,
    For the storage of the trend, there are three possibilities of file management:

    1) no limit
    2) limited file size
    3) limited in number of registrations.

    In case 2, what happens when the file is full?

    In case 3, what happens when the maximum number of records is reached?

    Thank you

     
  • jeromebunel

    jeromebunel - 2020-10-16

    Hello.
    I'm surprised no one reacted to my previous post.

    Maybe I explained badly.

    So,
    For the storage of the trend, there are three possibilities of file management:

    1) no limit
    2) limited file size
    3) limited in number of registrations.

    In case 2, what happens when the file is full?

    In case 3, what happens when the maximum number of records is reached?

    Thank you

     
  • jeromebunel

    jeromebunel - 2020-10-20

    Hello. I found a solution to my "STORAGE TREND" problem.
    In the "Trend Storage" dialog box, I use the "No limit" option.
    Then I regularly delete the oldest data from the SQLite database with an SQL query executed by a Python script.

    I share with you this request:

    *Delete from TblTrendData where
    (
        select
        date (TS / 1000000, 'unixepoch') as dt,
        where dt> date ('now', '- 30 days')
    ) *
    

    This is how I delete data older than 30 days.

    before executing this request; it is imperative to stop the recordings by setting to 0 "Record Conditions" variable

     

Log in to post a comment.