Reputation: 3
I am trying to uninstall Microsoft SQL Server from my local machine. Uninstall instructions say one must delete all local security groups for SQL Server components before uninstalling, however I cannot figure how to do this on Windows 10 Home. I have found online two ways of doing this, but neither has worked.
The first way is through 'Control Panel > Administrative Tools > Computer Management > Local Users and Groups'. Because I have Home edition, the 'Local Users and Groups' option does not seem to be available so I cannot delete anything this way. Running MCM.exe and trying to add the respective snap-in doesn't work either (error says "This snap-in cannot be used with this edition of Windows...").
The second way is through PowerShell. If I use the cmdlet:
Get-LocalGroup
I can see a SQL Sever group called:
SQLServer2005SQLBrowserUser$<computername>.
However, if I try to delete it using the cmdlet:
Remove-LocalGroup -Name "SQLServer2005SQLBrowserUser$<computername>"
I get an error message saying that no such group exists, as it cannot read what follow the dollar sign ($). Since -Name doesn't accept wildcards here, I don't know how to tell PowerShell to delete this group.
What am I doing wrong here? Is there another way to do this?
Sorry if this is a newbie question, but I am currently at a loss and cannot find any other ideas how to do this.
Thank you.
Upvotes: 0
Views: 577
Reputation: 32180
Try:
Remove-LocalGroup -Name 'SQLServer2005SQLBrowserUser$<computername>'
The problem is that variable names are expanded inside a double-quoted string. Using single quotes prevents PowerShell from parsing the string and thinking $<computername>
is a variable.
Upvotes: 2