How to execute a Postgresql procedure through Windows Task Scheduler -


how can execute procedure select my_proc() inside postgresql database using windows task scheduler? possible make script call procedure every 5 minutes? if it's possible need one.

i can't use pgagent in environment, sorry guys!

any tips?

use task scheduler run psql on desired schedule, command like:

psql -u username -d databasename -w -c 'select my_procedure()' 

and put password in .pgpass file, or set pgpass environment variable in task.

you don't need kind of script unless want command specific error handling.


Comments