Sorry for my late reply. Others have already answered you latest question (use the syntax for a regular expression).
You seem to have misunderstood my previous post.
Stevieb's solution is correct and will work for almost any imaginable input. A much simpler solution may be possible depending on the format of the data file.