DronaBlog

Tuesday, June 23, 2020

Important Regular Expression (RegEx) for daily Use

In this article, we will explain how to use Regular Expressions (Reg Ex) for daily use. We will be using  RegEx with multiple tools.

1. Regular Expressions in Notepad++

A. Case 1: Removing the last comma in the document
e.g.  Abc,,Pqr
XYZ,ABC,
DWD, XXX,

Regex: ,(?! )$   (This will detect the last comma in each statement)

B. Cae2: Remove duplicate values 
Regex: ^(.*?)$\s+?^(?=.*^\1$)
To remove duplicate lines just press Ctrl + F and provide RegEx mentioned above.

No comments:

Post a Comment

Please do not enter any spam link in the comment box.

What is CRM system?

  In the digital age, where customer-centricity reigns supreme, businesses are increasingly turning to advanced technologies to manage and n...