delete job history
select
j.name as ‘JobName’,
run_date,
run_time,
h.*
From msdb.dbo.sysjobs j
INNER JOIN msdb.dbo.sysjobhistory h
ON j.job_id = h.job_id
where j.enabled = 1 –Only Enabled Jobs
order by JobName, h.run_date, h.run_time desc
delete from msdb.dbo.sysjobhistory
where instance_id =’xxx’