Execute Stored Procedure with SQL Task Action Failing (exec msdb.dbo.sp_start_job)


Badge +1

I am attempting this query with an Execute SQL action:

exec msdb.dbo.sp_start_job @job_name=test

And I get this error:

The execution returned an unexpected error.
The specified @job_name ('test') does not exist.

 

The same statement works when I run it using SSMS:

exec msdb.dbo.sp_start_job @job_name=test

result: Job 'test' started successfully.

 

I copied and pasted between SSMS and Nintex to be certain that I am using the exact same job name.

 

Any ideas would be appreciated. Thank you!

 


5 replies

Badge +1

bump... still working on this one, any ideas?

Userlevel 6
Badge +22
Hi,
What Build of Nintex Worklfow are you using?
I have been testing passing a parameter to a stored procedure in my 2013 environment and it works as expected.
It wouldnt be the encoding of the Single Quotes that is causing the issue would it?
Badge +1

I am using Nintex for SharePoint 2016 On Premesis. Still having this issue.

 

I tried without quotes at all and it still fails. The exact same string runs in SSMS with or without a single quote around the job name.

 

I'd appreciate any other thoughts you might have. Thank you!

Badge +4

Have you tried a basic SQL script, like:

SELECT * FROM [table];

To make sure Nintex is connecting successfully with your SQL server.

Badge +10
Did you fix this issue, I am getting permission issue, but works on ssms

Reply