My e-Notes about Cloud, K8s, OpenShift, DataScience, Machine Learning, Python, Data Analytics, DataStage, DWH and ETL Concepts


Saturday, 12 August 2017

Delete all lines in Notepad++ except lines containing a pattern

Who dont want to keep the only items which needed and we want to have when working with lots of junk data and want to fetch only which requires :-)

This can be done very easily in NotePad++ .

1. Use Ctrl-F to open Search box and  Select "Mark"

2. Put the Pattern in "Find What" box (in my case, I want to keep "Singh" only)

3. Then Click on Mark All to Mark all the lines which is having "Singh" in it.

4. When Marked, it will look like below -

5. After marking, Close this pop-up and Go To Search --> Bookmark --> Remove Unmarked Lines

As soon as Click on Remove Unmarked Lines, it will delete the all lines other than marked line.

Like the below page to get update


The postings on this site are my own and don't necessarily represent IBM's or other companies positions, strategies or opinions. All content provided on this blog is for informational purposes and knowledge sharing only.
The owner of this blog makes no representations as to the accuracy or completeness of any information on this site or found by following any link on this site. The owner will not be liable for any errors or omissions in this information nor for the availability of this information. The owner will not be liable for any losses, injuries, or damages from the display or use of his information.