anpatel
anpatel

Reputation: 1962

How to automatically execute stored procedures in a particular sequence, or use an SSIS package to execute stored procedures?

I have created 2 stored procedures that need to be executed in a specific sequence.

I just do not know how to do this. I also want to do it automatically everyday with GETDATE() as the parameters to both procedures.

Is there an SSIS package I can create to execute these two procedures in the proper sequence for me?

Upvotes: 1

Views: 698

Answers (2)

Dominic Goulet
Dominic Goulet

Reputation: 8113

You can also create a SSIS package that will include 2 Execute SQL Task with a precedence constraint between them with something like exec [MyStoredProcedure] @MyParam = GetDate(); as the sql command to execute.

Upvotes: 1

Joe Stefanelli
Joe Stefanelli

Reputation: 135818

You want to create a job, make each procedure call a step within the job and then run the job on a defined schedule.

Upvotes: 3

Related Questions