Hello
Thank you for your question and reaching out. I can understand you are having query\issues related to SQL uninstallation error.
First of please reboot your Computer and check if the issue resolved automatically.
If still issue persists follow below steps which should help you to resolve the issue.
- Disable any Antivirus program or Windows firewall you may have for temporary purpose.
- Run sfc /scannow from elevated prompt.
- Run below DISM commands from elevated prompt.
DISM /Online /Cleanup-Image /CheckHealth
DISM /Online /Cleanup-Image /ScanHealth
DISM /Online /Cleanup-Image /RestoreHealth
- Then try to Uninstall SQL from Control Panel -> Programs and Features
--If the reply is helpful, please Upvote and Accept as answer--