Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
sqlserverdeveloper
Posting Yak Master
243 Posts |
Posted - 2008-05-13 : 17:28:56
|
I am not sure if we can execute SSIS package using t-sql, but I want to do the following:Step1. Execute SSIS package1Step2. Check for the file1.txt in c drive using the below code:Declare @result intexec xp_fileexist 'c:\file1.txt', @result output IF (@result = 1) --if file exists exec ssis package begin Execute SSIS package2 endIf we can't use t-sql, please let me know how I can do that as part of sql job. Thanks!! |
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2008-05-13 : 17:33:27
|
It took me about 30 seconds to find the answer by googling your problem. The answer is run dtexec to execute SSIS packages from the command line (or from xp_cmdshell).Tara KizerMicrosoft MVP for Windows Server System - SQL Serverhttp://weblogs.sqlteam.com/tarad/Database maintenance routines:http://weblogs.sqlteam.com/tarad/archive/2004/07/02/1705.aspx |
 |
|
|
|
|