Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

1192.Text file parser -- How to extract lines that matching the list of russian speaking names?

User: vlad -- 2014-04-07          << 1191  1193 >>
Hits: 1111
Type: Text file parser   
Search all Text file parser examples
Description:
I have notepad file with 100,000 lines of names, phone numbers and emails.
I want to do bulk find with the list of russian speaking names. I have about 200 of them. I want software to look through each line and if anything is matching to the search request I want the software to pull out that line and put it in a separate file. I want all names that it pulls to be placed into new single file. Thanks.
Input Sample:
List.txt:
Vladimir, Boris, Igor, Oleg, Andrei, Andrey, Tolik, Anatoliy, Kiril, Fedor, Alex, Natalia, Natasha

Input file:
(some lines contain words in List.txt)
Output Sample:
Output file:
Extract lines that contain words in list.txt from input file
Answer:
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
Assume the list of russian speaking names is in list.txt, like:
Vladimir, Boris, Igor, Oleg, Andrei, Andrey, Tolik, Anatoliy, Kiril, Fedor, 
Alex, Natalia, Natasha 

1. ctrl-o open list.txt
2. ctrl-h open 'replace' window
* set 'replace with pattern' to:

3. click 'replace', you will get a string like:
\b(Vladimir|Boris|Igor|Oleg|Andrei|Andrey|Tolik|Anatoliy|Kiril|Fedor)\b

4. ctrl-o open source text file.
5. ctrl-h open 'replace' window
* set 'replace unit' to 'Line'
* set 'search for pattern' to the string you just get:

* set 'replace with pattern' to:

* uncheck 'print unmatched unit' option
* check 'ignore case' option
6. click 'replace', done
7. ctrl-s save the result to a new file.

Screenshot 1:  Replace_Window


Screenshot 2:  Replace_Window


Similar Examples:
How to extract all lines that has more than 2 numbers? (61%)
How to extract all lines that has no leading spaces? (60%)
How to extract all lines that containing ABC or DEF with original order? (59%)
How to extract all lines that contain "abc" from multiple files? (57%)
How to extract lines containing only name and address? (57%)
How to extract all links that contain imprint from a webpage? (56%)
How to extract all lines containing words in specified file? (55%)
How to extract 3 lines from each file randomly? (55%)

Check Demo of Text file parser
Keywords:
notepad  phone numbers  phone number  anything  software  emails  matching  about  phone  chin  notepad replace with pattern  extract all phone numbers  matching lines  line matching  extract all lines with numbers  extract phone  find and replace all numbers in a text file  extract text and numbers