I am looking for some assistance with searching for a match against a specific string in a text file using Powershell. I have researched numerous methods so far and can't seem to determine how to satisfy this criteria:
I need to look for the string '20180125', and export the entire line to a new file ONLY when that string is found in the position in Green. If it is located at the red position, I don't care about the line. (But I DO care if it i located in both positions...)
I've tried some REGEX variations but I am having difficulty. I thought perhaps if I used Search-String with a pattern that it should suffice, I just can't figure out what that pattern needs to look like to match '20180125' only when it exists in the position in GREEN.