Wednesday, March 21, 2012

Creating a semaphore file on a network drive

Good Morning,

I'm hoping that someone can help me. I have a SQL 2005 SSIS package that will run Friday mornings to empty/load a table with data from another database. On Friday evenings I'll need to run another package, but want to make sure the table load completed prior to launch. For this I planned to use a file watcher task, however I cannot for the life of me figure out how to output a 'done' semaphore, from the morning job, to a networked drive.

A file system task will not work because there is not a 'create file' option. I do not have an existing file that I can rename either.

I tried an execute process task running cmd.exe with the following argument:

Code Snippet

echo Done> \\NetworkedServer\ftproot\Load.Done

This fails because UNC paths are not recognized. (The package executes from another server so I cannot use a local path, nor am I allowed to set-up a local share.)

Can someone offer an alternative suggestion? I'm really hoping this is easier than I'm making it.

Thank you in advance,

Roger

Why not have the first package write a value to a SQL table that the second package queries?|||You coud try a simialr aproach using a table. You can update or insert a row to indicate the status of the process. Then the next package will query that table and decide whether to run or not.

No comments:

Post a Comment