question

Teen-0523 avatar image
0 Votes"
Teen-0523 asked AnuragSharma-MSFT commented

SQL server agent Job execute stored procedure with parameters

Hi,
I would like to create an sql server agent job which executes a stored procedure that has multiple parameters.

I looked at the below link but I am not sure how to proceed.

https://social.msdn.microsoft.com/Forums/en-US/6a136d77-dd92-4e7a-94c4-ff038836bff2/send-parameters-to-sql-server-agent-jobs-job-steps?forum=sqltools

Appreciate your help.

azure-sql-database
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi @Teen-0523, just wanted to check if you need any other details. If answer helped, you can mark it 'Accept Answer'

0 Votes 0 ·

1 Answer

AnuragSharma-MSFT avatar image
0 Votes"
AnuragSharma-MSFT answered

Hi @Teen-0523, welcome to Microsoft Q&A forum

I am assuming you are talking about on-premise SQL Server and not Azure SQL. Below is one stack thread that has clear steps to execute a stored procedure with input parameters. It is having one parameter but you can extend the concept to include multiple parameters. Please check the first answer in it:

Create SQL Server Agent job for stored procedure with input parameter

Please let me know if this helps or else we can discuss further.


If answer helps, you can mark it 'Accept Answer'




5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.