sql-server-2008powershell

PowerShell - List all SQL instances on my system?


Is there a Powershell command to list all SQL instances on my system? (MS SQL 2008)


Solution

  • Just another way of doing it...can be a little quicker than SQLPS to get a quick answer.

    
    (get-itemproperty 'HKLM:\SOFTWARE\Microsoft\Microsoft SQL Server').InstalledInstances