Skip to main content

Hi forum,

 

I'm very new to FME Flow. I need to set up a schedule using cron expression for 07:00 Monday to Saturday, all year. I've entered...

 

0 7 * * 1-6

 

However FME Flow gives a message: "Invalid cron expression: 0 7 * * 1-6"

 

I cant see what's wrong with it. Any thoughts?

 

See attached image.

Swk_cronThanks,

Stuart

 

 

Please see https://community.safe.com/s/article/writing-cron-expressions-to-schedule-fme-server-jo

I think it should be

0 0 7 ? * MON-SAT

 


Personally, I always end up using this CRON generator, since I end up forgetting the syntax between uses: https://www.freeformatter.com/cron-expression-generator-quartz.html

Which would give you:

0 0 7 ? * MON,TUE,WED,THU,FRI,SAT *

 


Please see https://community.safe.com/s/article/writing-cron-expressions-to-schedule-fme-server-jo

I think it should be

0 0 7 ? * MON-SAT

 

Yes, that worked. Thank you.

Personally, I always end up using this CRON generator, since I end up forgetting the syntax between uses: https://www.freeformatter.com/cron-expression-generator-quartz.html

Which would give you:

0 0 7 ? * MON,TUE,WED,THU,FRI,SAT *

 

Most Google guidance I found suggested five fields:


·         minute of the hour (0-59), or leave as *

·         the hour (0-23), or leave as *

·         day of the month (1-31), or leave as *

·         month (1-12), or leave as *

·         day of the week (0-6 where 0 or 7 is Sunday), or leave as *


Thus my effort of 0 7 * * 1-6



I didn’t realise Flow wanted it’s cron expressions to be a bit more expanded that that.



Thanks,

Reply