I am trying to return results only for lines that contain matching text via cmd.
In this case the line must match in both "Name" and "Surname".
Read though http://ss64.com/nt/findstr.html, and tried the first example
findstr "James Henry" sam.txt >sam2.txt
Unfortunately, this also returns all lines that contain just James and just Henry in them. Only a the line which contains "James" and "Henry" should be returned.
example line that should be returned
James Edgar Henry 228559
example line that should not be returned
James Peters 148825
Any assistance appreciated