/*
disables sql jobs.
*/
--EXEC msdb.dbo.sp_update_job @job_name = N'[jobName]', @enabled = 0;
-- DECLARE @JobName varchar(max) = '[jobName]'
-- UPDATE msdb.dbo.sysjobs
-- SET enabled = 0
-- WHERE name = @JobName;

DECLARE @JobName NVARCHAR(128) = N'[jobName]';

IF EXISTS (
    SELECT 1
    FROM msdb.dbo.sysjobs
    WHERE name = @JobName
)
BEGIN
    EXEC msdb.dbo.sp_update_job 
        @job_name = @JobName,
        @enabled = 0;
END