/build/static/layout/Breadcrumb_cap_w.png

How to generate a K1000 report for SQL Server installations

I need to generate a report on KACE with any server in our system having (Under Services) MSSQLSERVER.

All of our servers are named Sr###  (example) Sr19 or Sr205 ect.

If the report also pulls workstations it won't work because 98% of our machines have SQL.

 

I found something similar here: http://www.itninja.com/question/need-a-kace-report-for-all-sql-server-installations-1

 

But this is ALL sql installations. I only need servers with MSSQLSERVER listed as a service.

SELECT M.NAME, CS_MODEL AS Model, CHASSIS_TYPE as Type, IP, USER_LOGGED,
GROUP_CONCAT(DISTINCT S.DISPLAY_NAME SEPARATOR '\n') AS SOFTWARE,
GROUP_CONCAT(DISTINCT S.DISPLAY_VERSION SEPARATOR '\n') AS VERSION
FROM MACHINE M
LEFT JOIN MACHINE_SOFTWARE_JT ON M.ID = MACHINE_SOFTWARE_JT.MACHINE_ID
LEFT JOIN SOFTWARE S ON MACHINE_SOFTWARE_JT.SOFTWARE_ID = S.ID
WHERE S.DISPLAY_NAME LIKE 'Microsoft SQL Server 2005 Express%'
OR S.DISPLAY_NAME LIKE 'Microsoft SQL Server 2000%'
OR S.DISPLAY_NAME LIKE 'Microsoft SQL Server 2005 Compact%'
GROUP BY M.NAME
ORDER BY NAME

 

Can anyone help?


0 Comments   [ + ] Show comments

Answers (1)

Posted by: gcarpenter 12 years ago
Green Belt
2

Let me know if this works.  I have my server as CHASSIS_TYPE 'server', so change that name if necessary.

Also, none of my servers have SQL on them.

SELECT M.NAME
  , CS_MODEL AS Model
  , CHASSIS_TYPE as Type
  , IP
  , USER_LOGGED
  , GROUP_CONCAT(DISTINCT S.DISPLAY_NAME SEPARATOR '\n') AS SOFTWARE
  , GROUP_CONCAT(DISTINCT S.DISPLAY_VERSION SEPARATOR '\n') AS VERSION
FROM MACHINE M
  LEFT JOIN MACHINE_SOFTWARE_JT ON M.ID = MACHINE_SOFTWARE_JT.MACHINE_ID
  LEFT JOIN SOFTWARE S ON MACHINE_SOFTWARE_JT.SOFTWARE_ID = S.ID
WHERE CHASSIS_TYPE LIKE 'server'
  AND (S.DISPLAY_NAME LIKE 'Microsoft SQL Server 2000%' OR S.DISPLAY_NAME LIKE 'Microsoft SQL Server 2005 Compact%')  
GROUP BY M.NAME
ORDER BY NAME

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ