# Set Cron Job - Scheduler

**URL:** <https://forum.servoy.com/t/set-cron-job-scheduler/19283>\
**Category:** Classic Servoy\
**Created:** [June 4, 2017, 11:57am UTC](https://forum.servoy.com/t/set-cron-job-scheduler/19283 "2017-06-04T11:57:05Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ayadav1](https://avatars.discourse-cdn.com/v4/letter/a/8c91f0/32.png) [@ayadav1](https://forum.servoy.com/u/ayadav1)\
**Post date:** [June 4, 2017, 11:57am UTC](https://forum.servoy.com/t/set-cron-job-scheduler/19283/1 "2017-06-04T11:57:05Z")

</div>

Hi,  
I want to set a Cron job in my application to execute 1 specific method to update the database value.  
I have checked the Servoy wiki and found that we can set a Cron job using addCron method.  
But after implementation I have found that method is being executed only once.  
I want to set Cron for every 5 mins. Please share the syntax to add Cron job.  
And I want to run without client login.

Thanks in advance.

Abhishek

---

<div class="post-metadata">

**Author:** ![ROCLASI](https://yyz2.discourse-cdn.com/flex010/user_avatar/forum.servoy.com/roclasi/32/4371_2.png) [@ROCLASI](https://forum.servoy.com/u/ROCLASI)\
**Post date:** [June 4, 2017, 2:09pm UTC](https://forum.servoy.com/t/set-cron-job-scheduler/19283/2 "2017-06-04T14:09:52Z")

</div>

Hi Abishek,

Cron uses a specific format to define when a job should run (_seconds, minutes, hours, day of month, month, day of week, year_). It’s very versatile which also makes a bit complex.  
To run a job every 5 minutes you use the time-string “0 0/5 \* \* \* ?” (_0 seconds, every 5 minutes starting from the top of the hour_).  
You can read more about it [here](http://www.quartz-scheduler.org/documentation/quartz-2.x/tutorials/crontrigger.html).

Hope this helps.

---

<div class="post-metadata">

**Author:** ![jeffrey.vandenhondel](https://avatars.discourse-cdn.com/v4/letter/j/ed8c4c/32.png) [@jeffrey.vandenhondel](https://forum.servoy.com/u/jeffrey.vandenhondel)\
**Post date:** [July 26, 2017, 9:31am UTC](https://forum.servoy.com/t/set-cron-job-scheduler/19283/3 "2017-07-26T09:31:52Z")

</div>

And if you want a easy generator for these cron jobs use [this](http://www.cronmaker.com/).
