Solved

Query for SQL machines with SQL Server instaled

Posted on 2010-08-26
3
722 Views
Last Modified: 2013-11-21
I need a query to tell me that SCCM versions and the number of installations of SQL Server is on the site
0
Comment
Question by:ggarate
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 31

Expert Comment

by:merowinger
ID: 33541745
not the whole solution as i don't have the time for it, but a step in the correct direction
SELECT distinct dbo.v_R_System.Netbios_Name0,dbo.v_Add_Remove_Programs.DisplayName0
FROM dbo.v_Add_Remove_Programs INNER JOIN dbo.v_R_System ON dbo.v_Add_Remove_Programs.ResourceID = dbo.v_R_System.ResourceID
WHERE dbo.v_Add_Remove_Programs.ProdID0 not like '{%' and
dbo.v_Add_Remove_Programs.displayname0  like 'Microsoft SQL Server 2005'
or dbo.v_Add_Remove_Programs.displayname0  like 'Microsoft SQL Server 2005 (64-Bit)'
or dbo.v_Add_Remove_Programs.displayname0  like 'Microsoft SQL Server 2008 (64-bit)'

Open in new window

0
 
LVL 6

Expert Comment

by:TarekIsmail
ID: 33562608
HI ,
you make query based on the service name as

select distinct SMS_R_System.NetbiosName, SMS_R_System.ClientVersion, SMS_R_System.IPAddresses, OSname.Caption from  SMS_R_System inner join SMS_G_System_SERVICE on SMS_G_System_SERVICE.ResourceID = SMS_R_System.ResourceId inner join SMS_G_System_OPERATING_SYSTEM on SMS_G_System_OPERATING_SYSTEM.ResourceID = SMS_R_System.ResourceId inner join SMS_G_System_OPERATING_SYSTEM as OSname on OSname.ResourceID = SMS_R_System.ResourceId where SMS_G_System_SERVICE.DisplayName = "SQL Server (MSSQLSERVER)"

Open in new window

0
 
LVL 6

Accepted Solution

by:
TarekIsmail earned 500 total points
ID: 33562611
select distinct SMS_R_System.NetbiosName, SMS_R_System.ClientVersion, SMS_R_System.IPAddresses, OSname.Caption from  SMS_R_System inner join SMS_G_System_SERVICE on SMS_G_System_SERVICE.ResourceID = SMS_R_System.ResourceId inner join SMS_G_System_OPERATING_SYSTEM on SMS_G_System_OPERATING_SYSTEM.ResourceID = SMS_R_System.ResourceId inner join SMS_G_System_OPERATING_SYSTEM as OSname on OSname.ResourceID = SMS_R_System.ResourceId where SMS_G_System_SERVICE.DisplayName = "SQL Server (MSSQLSERVER)"
0

Featured Post

Free NetCrunch network monitor licenses!

Only on Experts-Exchange: Sign-up for a free-trial and we'll send you your permanent license!

Here is what you get: 30 Nodes | Unlimited Sensors | No Time Restrictions | Absolutely FREE!

Act now. This offer ends July 14, 2017.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you considered what group policies are backwards and forwards compatible? Windows Active Directory servers and clients use group policy templates to deploy sets of policies within your domain. But, there is a catch to deploying policies. The…
Know what services you can and cannot, should and should not combine on your server.
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question