Skip to content

Latest commit

 

History

History
34 lines (32 loc) · 981 Bytes

README.md

File metadata and controls

34 lines (32 loc) · 981 Bytes

sqlite3_extensions

collection of sqlite3 extensions

cron.c

  • cron_match(date text, cron_entry text) allows you to compare dates against cron entries, whether they match or not
  • f.e.:
    • select cron_match('2000-01-01 00:03:00', '*/3 * * * *'); returns 1
    • select date from test1 where cron_match(date, '*/9 */10 * * *'); returns
      date
      2000-01-04 10:27:00
      2000-01-04 10:36:00
      2000-01-04 10:45:00
      2000-01-04 10:54:00
      2000-01-04 20:00:00
      2000-01-04 20:09:00
      2000-01-04 20:18:00
      2000-01-04 20:27:00
      2000-01-04 20:36:00
      2000-01-04 20:45:00
      2000-01-04 20:54:00
      2000-01-05 00:00:00
      2000-01-05 00:09:00
      2000-01-05 00:18:00
      2000-01-05 00:27:00
      2000-01-05 00:36:00
      2000-01-05 00:45:00
      2000-01-05 00:54:00
      2000-01-05 10:00:00
      2000-01-05 10:09:00
      2000-01-05 10:18:00
      2000-01-05 10:27:00
      2000-01-05 10:36:00