sql-server - Select–String :术语“Select–String”未被识别为 cmdlet、函数、脚本文件或可运行程序的名称
问题描述
我正在尝试在 Windows 8.1 pro 中完全卸载 sql server 2016 实例,但出现此选择字符串错误。这是代码:
`$a = c:\temp\msiinv.exe -s | Select–String "SQL Server" -Context 1,1;
$a = $a -replace "Product code: ","msiexec /x """;
$a = $a -replace ">", "rem";
$a = $a -replace "\t", "";
$a = $a -replace "}","}""";
$a | Out-File c:\temp\remove.bat -encoding ascii;`
由于设置不当,我之前曾两次安装和卸载服务器实例,现在我希望将其从我的机器中完全删除。检查下面 的 ss-在此处输入图像描述 PS 我正在使用最新版本的 WindowsPS 和 .netfw v4.8
解决方案
推荐阅读
- python - Py4J 序列化:AttributeError:“dict”对象没有属性“_get_object_id”
- r - 比较不区分大小写的两列
- react-native - 每次单击时如何使文本输入可编辑?
- java - 单元测试 gRPC 的最佳实践
- javascript - 添加 JS 文件 - Webpack - 静态站点样板
- pandas - 如何使用熊猫将单个单元格与python中数据框的整个列进行比较
- javascript - 清除超时后的 UnhandledPromiseRejectionWarning
- react-native - 世博会矢量图标,字体未加载
- amazon-web-services - 将变量放入 Redshift 存储过程中的 INSERT 语句中
- javascript - 不能在 jQuery.get() 中使用 Jinja 变量