Patching report
Hi I am trying to create a report that shows me failed patches by label and lists the machine names that failed. I want to exclude any inactive or disabled patches. I've gotten this report close, but I can't get it quite right. Any help would be greatly appreciated.
0 Comments
[ + ] Show comments
Answers (4)
Please log in to answer
Posted by:
tayana
13 years ago
Here is what I have:
SELECT PP.TITLE AS DISPLAY_NAME,
M.NAME AS ComputerName,
SYSTEM_DESCRIPTION,
M.USER_LOGGED as USER_LOGGED
FROM PATCHLINK_MACHINE_STATUS MS
JOIN KBSYS.PATCHLINK_PATCH PP ON PP.UID = MS.PATCHUID
JOIN MACHINE M ON M.ID = MS.MACHINE_ID
WHERE (MS.DEPLOY_ATTEMPT_COUNT >= MS.MAX_DEPLOY_ATTEMPT and MS.STATUS != 'PATCHED') or MS.STATUS = 'FAIL' or (MS.DEPLOY_STATUS = 'FAIL' and MS.STATUS != 'PATCHED')
ORDER BY PP.TITLE
SELECT PP.TITLE AS DISPLAY_NAME,
M.NAME AS ComputerName,
SYSTEM_DESCRIPTION,
M.USER_LOGGED as USER_LOGGED
FROM PATCHLINK_MACHINE_STATUS MS
JOIN KBSYS.PATCHLINK_PATCH PP ON PP.UID = MS.PATCHUID
JOIN MACHINE M ON M.ID = MS.MACHINE_ID
WHERE (MS.DEPLOY_ATTEMPT_COUNT >= MS.MAX_DEPLOY_ATTEMPT and MS.STATUS != 'PATCHED') or MS.STATUS = 'FAIL' or (MS.DEPLOY_STATUS = 'FAIL' and MS.STATUS != 'PATCHED')
ORDER BY PP.TITLE
Posted by:
dchristian
13 years ago
I think this is getting closer.
You said you wanted to organize by label.
Is that patch label or machine label?
You said you wanted to organize by label.
Is that patch label or machine label?
SELECT PP.TITLE AS DISPLAY_NAME,
M.NAME AS COMPUTERNAME,
SYSTEM_DESCRIPTION,
M.USER_LOGGED AS USER_LOGGED
FROM PATCHLINK_MACHINE_STATUS MS,
KBSYS.PATCHLINK_PATCH PP,
MACHINE M
WHERE PP.UID = MS.PATCHUID
AND M.ID = MS.MACHINE_ID
AND PP.IS_SUPERCEDED = 0
AND PP.STATUSID = 'ACTIVE'
AND ( ( MS.DEPLOY_ATTEMPT_COUNT >= MS.MAX_DEPLOY_ATTEMPT
AND MS.STATUS != 'PATCHED' )
OR MS.STATUS = 'FAIL'
OR ( MS.DEPLOY_STATUS = 'FAIL'
AND MS.STATUS != 'PATCHED' ) )
ORDER BY PP.TITLE
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.