You are here:  » process automation


process automation

Submitted by shams995 on Mon, 2013-06-03 12:13 in

Hi,

I am trying to integrate automated upload + slow import. By itself, i have sorted the 2 out individually, but how can I make a job that does the same thing in sequence (provided it did not error out downloading latest csv). I host on windows platform and the hosting guys allow jobs that call specific urls (more to make sure the site can be reached).

Thanks a lot!
Shams

Submitted by support on Mon, 2013-06-03 12:52

Hello Shams,

Under Linux, multiple commands would be "chained" within a single CRON (scheduled) job by separating them by semi-colon, for example

cd /home/example.com/public_html/scripts;/usr/bin/php fetch.php @ALL;/usr/bin/wget -O /dev/null "http://www.example.com/scripts/import_slow.php?password=mypassword"

This means that each command is executed in sequence, and not before the previous command has completed.

Under Windows, I think the easiest way to achieve the same would be to create a .bat (batch) file containing each command on a new line:

automation.bat

cd c:\path\to\htdocs\scripts
command 1
command 2

...and then instead of scheduling the change directory, command 1 and command 2 individually, create a single scheduled job using:

cmd.exe c:\path\to\automation.bat

Hope this helps!

Cheers,
David.
--
PriceTapestry.com