List of articles   Choose language


Timer


I propose to append timers - procedures like triggers, several parameters are specified at creating of them: from which date-and-time ('start') and to which date-and-time ('end') timer is active (timer does not deleted from database after end of this time), length of interval of time ('per'), on which timer is called one or several times, and also displacements of time of call ('schedule') inside interval of time.

create timer TimerName
  start      YY.MM.DD/HH.MM.SS
  end        YY.MM.DD/HH.MM.SS
  schedule  (YY.MM.DD/HH.MM.SS, YY.MM.DD/HH.MM.SS, ...)
  per        YY.MM.DD/HH.MM.SS;
For example
create timer t1 schedule (01/0, 03/0, 10/0) per 01.00/0 as  ;    -- 1-st, 3-rd, 10-th day of each month
create timer t2 schedule (0/0.05, 0/0.10, 0/0.20) per 0/01 as  ; -- 5-, 10-, 20-th minutes of each hour
create timer t3 schedule (0) per 0/24 as  ;                      -- each 24 hours

P.S.

Article is guide to implement ideas of p.201-203 of pdf-document.



Dima Turin, dmitryturin@yandex.ru



List of articles   Choose language


Используются технологии uCoz