Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Start SSIS package from a SQL Agent job Expand / Collapse
Author
Message
Posted Thursday, October 18, 2007 9:35 AM
SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: Thursday, March 27, 2014 2:54 PM
Points: 212, Visits: 466
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


Post #412290
Posted Thursday, October 18, 2007 9:59 AM
Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Monday, July 21, 2014 7:33 AM
Points: 1,140, Visits: 963
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.
Post #412301
Posted Friday, March 16, 2012 6:56 AM
SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: Thursday, April 17, 2014 12:27 PM
Points: 264, Visits: 230
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'
Post #1268195
Posted Friday, March 16, 2012 7:13 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Today @ 3:45 AM
Points: 1,312, Visits: 2,490
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
Post #1268213
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse