SCCM application/task sequence SQL query status 10005
Hello everybody. I’m looking for a SCCM SQL query with which I can read the status 10005 of an application or a task sequence (application preferred). The query must contain the installation time and the machine name. Unfortunately I don’t know in which tables I should look for the status and whether applications output this or whether I need absolutely a task sequence. The application should distribute a VB script over several computers and then execute it on the computer.
Answers ( 2 )
If you want to get information on basis of status messages I suggest to create state message query.
You can use below query and change the attribute value to your deploymentID.
left join SMS_StatMsgInsStrings on SMS_StatMsgInsStrings.RecordID = SMS_StatusMessage.RecordID
left join SMS_StatMsgAttributes on SMS_StatMsgAttributes.RecordID = SMS_StatusMessage.RecordID
where SMS_StatMsgAttributes.AttributeID = 401 and SMS_StatMsgAttributes.AttributeValue = “1002000B” and SMS_StatMsgAttributes.AttributeTime >= ##PRM:SMS_StatMsgAttributes.AttributeTime##
order by SMS_StatMsgAttributes.AttributeTime DESC
Have you seen the post from Ankit … it will surely help you
SCCM Application Deployment Custom Report SQL Query | ConfigMgr https://www.anoopcnair.com/sccm-application-deployment-custom-report-sql-query-configmgr/