Check Enabled Cron Jobs on pg_cron

Extra short one today!

But something I needed.

To check the running jobs in pg_cron, you can query the cron.job table, which provides details about the jobs that are currently running. While it doesn't directly show running jobs, it provides a list of all scheduled jobs.

SELECT * FROM cron.job;

This will give you useful information such as the schedule, job name, the command that was run, and a few other bits.

By using this query, you can effectively find the information you need about your existing cron jobs.

Postgresql
Avatar for Niall Maher

Written by Niall Maher

Founder of Codú - The web developer community! I've worked in nearly every corner of technology businesses; Lead Developer, Software Architect, Product Manager, CTO and now happily a Founder.

Loading

Fetching comments

Hey! 👋

Got something to say?

or to leave a comment.