dwilliscp
SSCrazy Eights
Points: 9270
More actions
May 4, 2012 at 11:55 am
#261037
Does anyone know where MS is storing the Job Category Name? So I could link to the table and convert the category_id to its name?
SELECT [job_id]
,[category_id]
FROM [msdb].[dbo].[sysjobs]
seth delconte
SSCertifiable
Points: 6388
May 4, 2012 at 12:39 pm
#1483720
SELECT j.[job_id], j.[category_id], c.name [category_name]
FROM [msdb].[dbo].[sysjobs] j
JOIN [msdb].[dbo].[syscategories] c
on j.category_id = c.category_id
🙂
_________________________________seth delcontehttp://sqlkeys.com
Geoff A
SSChampion
Points: 11511
#1483721
SELECT T1.[job_id]
,T1.[category_id], T2.name
FROM [msdb].[dbo].[sysjobs] T1 join msdb.dbo.syscategories T2
on T1.category_id = T2. category_id
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply