• You can use CmdExec method (Using operating system command) also to run the command.

    To Use the extended stored procedure xp_cmdShell, it needs to be enabled. By default it is disabled due to security concerns.

    The Job Step will be some thing like this:

    EXEC @ReturnCode = msdb.dbo.sp_add_jobstep @job_id=@jobId, @step_name=N'copy file',

    @step_id=1,

    @cmdexec_success_code=0,

    @on_success_action=1,

    @on_success_step_id=0,

    @on_fail_action=2,

    @on_fail_step_id=0,

    @retry_attempts=0,

    @retry_interval=0,

    @os_run_priority=0,

    @subsystem=N'CmdExec',

    @command=N'ccopy c:\myfolder\myfile.txt d:\yourfolder\yourfile.txt',

    @flags=0

    Cheers,
    Prithiviraj Kulasingham

    http://preethiviraj.blogspot.com/