Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Start SSIS package from a SQL Agent job


Start SSIS package from a SQL Agent job

Author
Message
Warren Peace
Warren Peace
SSC Veteran
SSC Veteran (223 reputation)SSC Veteran (223 reputation)SSC Veteran (223 reputation)SSC Veteran (223 reputation)SSC Veteran (223 reputation)SSC Veteran (223 reputation)SSC Veteran (223 reputation)SSC Veteran (223 reputation)

Group: General Forum Members
Points: 223 Visits: 476
I have a SQL job that kicks off to populate some tables with test data. I also have an SSIS package that copies the data to another development SQL server called ScrapAllData_RePopulate.

Within the SQL Agent job I want the final step to kick off my SSIS package. Can someone give an an example of how to do that?

Thanks
Adam Angelini
Adam Angelini
Ten Centuries
Ten Centuries (1.2K reputation)Ten Centuries (1.2K reputation)Ten Centuries (1.2K reputation)Ten Centuries (1.2K reputation)Ten Centuries (1.2K reputation)Ten Centuries (1.2K reputation)Ten Centuries (1.2K reputation)Ten Centuries (1.2K reputation)

Group: General Forum Members
Points: 1204 Visits: 1177
add a new job step. In the Type dropdown, select sql server integration services package. then you need to fill in the appropriate tabs. what you will fill in may vary greatly, so I can't really go into what you will need in there, but hopefully this gets you on your way.
mark_copley
mark_copley
SSC Veteran
SSC Veteran (264 reputation)SSC Veteran (264 reputation)SSC Veteran (264 reputation)SSC Veteran (264 reputation)SSC Veteran (264 reputation)SSC Veteran (264 reputation)SSC Veteran (264 reputation)SSC Veteran (264 reputation)

Group: General Forum Members
Points: 264 Visits: 240
You could also call the SSIS package directly too if you wanted

DECLARE @sqlCmd VARCHAR(1250) -- call to ssis package
,@returnCode INT -- returncode from package execution
,@ssisPath VARCHAR(1250) - location of ssis package

SET @ssisPath = '\\server\ssis\mySSISPackage.dtsx'
SELECT @sqlCmd = 'DTEXEC /F "' + @ssisPath + '"'

-- call ssis package and return result
EXEC @returnCode=Master..xp_cmdshell @sqlCmd
SELECT @returnCode AS '@returnCode'
Divine Flame
Divine Flame
SSCommitted
SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)

Group: General Forum Members
Points: 1573 Visits: 2801
Enabling xp_cmdshell just to execute the SSIS package? You already have the Integration Services Package step type in the agent job configuration. If you decide to call it from CMD anyway then you have "CMDExec" step type availabe in the job configuration.


Sujeet Singh
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search