Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Well, there, Jack, what you've listed is a hodge-podge of half-right answers.</p> <p>There are a lot of ways to start an SSIS package. However, the best way is probably <a href="http://msdn.microsoft.com/en-us/library/aa260289(SQL.80).aspx" rel="noreferrer"><code>sp_start_job</code></a>. Now, this implies that you've <a href="http://msdn.microsoft.com/en-us/library/ms190268.aspx" rel="noreferrer">created a job</a> that will run your SSIS package.</p> <p>A lot of times, this puppy fails because of credentials issues. Namely, you're trying to run the bloody thing as the SQL Server Agent account (aka <code>LOCAL SYSTEM</code>), which doesn't bode too well for execution abilities. So, you'll need to <a href="http://msdn.microsoft.com/en-us/library/ms190703.aspx" rel="noreferrer">create a Credential</a>, and then <a href="http://msdn.microsoft.com/en-us/library/ms189064.aspx" rel="noreferrer">a Proxy</a> for the job to run as. Therefore, what you need to do is thusly:</p> <pre><code>CREATE CREDENTIAL MyCred WITH IDENTITY 'CORP\MyUser', SECRET = '&lt;PassGoesHere&gt;' GO sp_add_proxy @proxy_name='MyProxy', @enabled = 1, @credential = 'MyCred' GO sp_grant_proxy_to_subsystem @proxy_name = 'MyProxy', @subsystem_id = 3 GO sp_add_job @job_name = 'MyJob', @enabled = 1 GO sp_add_jobstep @job_name = 'MyJob', @step_name = 'Run SSIS Package', @subsystem = 'CMDEXEC', @command = 'dtexec /F C:\Path\To\Package.dtsx', @proxy_name = 'MyProxy' </code></pre> <p>Meaningful docs:</p> <ol> <li><a href="http://msdn.microsoft.com/en-us/library/ms189522.aspx" rel="noreferrer"><code>CREATE CREDENTIAL</code></a></li> <li><a href="http://msdn.microsoft.com/en-us/library/ms188763(SQL.90).aspx" rel="noreferrer"><code>sp_add_proxy</code></a></li> <li><a href="http://msdn.microsoft.com/en-us/library/ms186760(SQL.90).aspx" rel="noreferrer"><code>sp_grant_proxy_to_subsystem</code></a></li> <li><a href="http://msdn.microsoft.com/en-us/library/ms182079(SQL.90).aspx" rel="noreferrer"><code>sp_add_job</code></a></li> <li><a href="http://msdn.microsoft.com/en-us/library/ms187358(SQL.90).aspx" rel="noreferrer"><code>sp_add_jobstep</code></a></li> </ol>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload