

This should also work even if 3 (or more) duplicates of the same StartTime, leaving ONLY the latest record. Lastly we can move the record numbers back to the start of the line. If the same then the current line would be removed which is your next criteria of not removing the latest timestamp. Then a simple regex (regular expression) would look at the current line StartTime and also at the next one. Thus the latest CreationTime number when duplicate records exist would be second (last) in that sequence. Then a numerical sort would place the duplicate StartTime records together and given the next number is also numerical it would sort that in increasing number order. So the new line format would be StartTime followed by CreationTime and Record number last. I’ll explain first the steps I’d take and then if you are fine with that I could provide some regular expressions to do it.Īs the first number is going to affect a numerical sort I’d want to move that to the end of the line. It looks like it should be an easy job to find duplicates. Then, just follow these instructions: Paste the text into Notepad++ (CTRL+V).Ĭlick TextFX → Click TextFX Tools → Click Sort lines case insensitive (at column)ĭuplicates and blank lines have been removed and the data has been sorted alphabetically.Said in Is there way to Search for duplicate records based on the column in notepad++ and delete the particular row:īut i want to know is there a way i can do it notepad++ ? The \r?\n should deal nicely with Windows and Unix lineendings. Such a block of duplicates (if it exists) is replaced with nothing. The find matches a line ^(.*\r?\n) and captures the line in \1 then it continues and tries to find \1 one or more times ( +) behind the first match. How it works: The sorting puts the duplicates behind each other.


Check Regular Expression in the lower left.sort line with Edit -> Line Operations -> Sort Lines Lexicographically ascending.If it is possible to change the sequence of the lines you could do:
