โ07-03-2023 10:57 PM
โ07-03-2023 11:41 PM
To schedule a job in a workflow to run every 30 days, follow these steps:
1. Go to the "Workflows" section in the sidebar.
2. Find the job you want to schedule in the "Name" column on the "Jobs" tab and click on it.
3. In the "Job details" panel, click on "Add trigger".
4. Select "Scheduled" as the trigger type.
5. Specify the period as "Monthly" and choose the starting time and time zone.
6. Click on "Save".
Example of a cron expression for running a job every 30 days:
0 0 1 */30 * ?
Please note that the cron expression may vary depending on your specific scheduling requirements and the platform you are using.
โ07-03-2023 11:57 PM
Hello @Vinay_M_R -> I want jobs to run on 30 days interval not on monthly. Reason for this to have log on every 30 days.
โ07-04-2023 12:38 AM
Hi @pcbzmani
A cron expression doesn't inherently support the concept of running a job for a specific number of days and then stopping. Cron is designed to schedule recurring tasks at regular intervals.
If you want to run a job every day for up to 30 days, you could use the cron expression "0 0 * * *" to run the job every day at midnight. However, you would need to implement additional logic outside of the cron schedule to stop the job after 30 days.
This could be done, for example, by storing the start date of the job in a database or file, and then checking this date each time the job runs. If the current date is 30 days or more after the start date, the job could then stop itself.
Again, the exact implementation of this would depend on the system you're using to schedule and run your jobs.
โ07-04-2023 01:41 AM
โ07-04-2023 04:39 AM
You could go to the crontab and set the expression as 0 0 */30 * *
โ07-04-2023 06:45 AM
This is not working. Getting Invalid Quartz Cron Expression
โ07-11-2023 10:05 PM
Could you try 0 0 0 1/30 * ? *
Databricks uses Quartz cron syntax and we have to provide 1/30 for day to achieve a schedule for 30 days.
Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you wonโt want to miss the chance to attend and share knowledge.
If there isnโt a group near you, start one and help create a community that brings people together.
Request a New Group