calling ssis package from stored procedure without using xp_cmdshell - sql

My application actually calls a stored procedure which inturn calls a package and execute it.Initially we are doing it using xp_cmdshell and dtexec but client disallows to use xm_cmdshell.Is there is any other way to do this?
Please help.

This scenario is discussed in the SSIS documentation. Another option would be a CLR procedure that runs the package, so instead of TSQL/xp_cmdshell you use CLR/Dts object model.

You could set up a job that runs the package and then use sp_start_job to execut the job
http://msdn.microsoft.com/en-us/library/ms403355.aspx
You can use these commands to create the job programatically
http://msdn.microsoft.com/en-us/library/ms181153.aspx

Related

Calling an SSIS package with SQL without using a job and specifying who the SSIS package will run as

I am trying to run an SSIS package using a stored procedure without using a job so that I can call multiple instances of the package without getting the job still in use error should multiple people want to use it at once. I've used the create and start execution procedures in the SSIS database which I have working but I also need the package to inherit the permissions of the person calling the procedure in order for it move some files during it's execution.
So far I'm using SELECT suser_name() to get the profile name of the person calling the procedure but I'm not sure where to use that next, will execute as follow through into the SSIS package if I run the start_execute procedure using it?

Best way to start SSIS catalog or SSIS package remotely

I need to execute an SSIS package or an SSIS catalog remotely. What is the best way to acomplish this?
I'm using:
Visual Studio 2012
SQL Server 2012
I am almost positive you need an integration server to accomplish this. The package is stored in the MSBD of the integration server and called by job or execution statement from within your code.
Siting MSDN http://msdn.microsoft.com/en-us/library/ms403355.aspx
you can create integration services catalog and host your project and packages inside it.
Now you can navigate to the package and execute it manually by providing all necessary parameters if any.
you can call the package by using an in-built stored proc "ssisdb.catalog.create_execution " and provide all necessary input and output parameters.

How to call stored procedure from OSB without using JDeveloper JCA adapter

I need help on OSB 11g. I want to call stored procedure from OSB. I got so many answers which guide to develop JCA adopter through JDeveloper and configure in OSB. But I dont want to depend on JDeveloper every time. Can anybody suggest me is there any way we can call stored procedure without using JDeveloper JCA adopter.
Please note that its not executing simple sql query, its calling stored procedure.
You Can use fn-bea:execute-sql function in Xquery. within it execute your procedure and assign in variable.
If you want to call Stored Procedure and don't want to use JCA, your best bet would be a Java Callout. Write a POJO to execute Stored Procedure.
Using java callout is the best option , where you don't have to use jca files, for that matter , J-dev. Bea-execute-sql only works for select queries.

Start SSIS Asynchronously from a stored proc

I need to start a SSIS package via a stored procedure. I chose to use 'exec dtexec' instead of starting a job to launch the package, so I can have the ability to set variable in the package. My problem is that I need the package to run asynchronously so that the stored procedure will return instead of it hanging or timing out.
What is the best practice for achieving this?
If you want Async operation with variables, I would construct a table to hold the variables you wanted to pass in, and an Agent job launched SSIS with them. Then you could use sp_start_job to launch that job asynchronously. The package could read the variables it needed from the table, or the job could read them to construct an appropriate launch command. The package could even update the table to indicate results back to BizTalk.
Use the stored proc to start a SQL Server Agent job that invokes the SSIS package...
You can't invoke directly from a stored proc (which is not a good idea anyway) and then have the stored proc terminate. You have to decouple the stored proc execution from the SSIS execution
Setting variables is easy though in SQL Server agent (GUI) and on command line (use /Set)

Run application in response to database event

I have a an application that needs to run at the end of a series of database jobs in SQL Server 2005. The application will do processing on the data that was created by these jobs.
What would be the best way to trigger the execution of this application?
Depending on the type of application, if it's non-interactive then you can write CLR stored procedure that can be executed like any other stored procedure call.
If you don't mind having the application run on the database server, just add a new job step and execute it as part of the job. The command type is "operating system command (CmdExec).