Reputation: 346
Im using the latest postgres version and im new with it. I just want to know how can i have an insert query statement that triggers every midnight or using now()::time = '23:59:59'? is it possible? Thanks in advance
Upvotes: 0
Views: 1394
Reputation: 245419
Postgres doesn't have anything out of the box to do what you need. You'll need something like pg_cron
to allow you to schedule queries:
https://github.com/citusdata/pg_cron
Or schedule the query using psql
via the system's cron
scheduler.
Upvotes: 4