[ACCEPTED]-Powershell - How to search for Whole Words (or) Exact Matches-powershell
Accepted answer
Try select-string -pattern "\.rtop\b"
.
You need to escape the dot, or it will 3 match any character; and the \b
word boundary 2 anchor ensures that the word does not continue 1 after rtop
.
You can use the -simplematch option of select-string 1 to do a literal match instead of regex.
Source:
stackoverflow.com
More Related questions
Cookie Warning
We use cookies to improve the performance of the site. By staying on our site, you agree to the terms of use of cookies.