I want to announce the new MultiReplace release 2.3.0.10, bringing new CSV features in Notepad 8.6.3.
Here’s what’s new:
Sorting Lines in CSV by Columns: Ascend or descend, combining columns in any prioritized order.
Deleting Multiple Columns: Simultaneously remove various columns, cleaning up any obsolete delimiters.
Clipboard Column Copying: Instantly copy columns, complete with original delimiters, into the clipboard.
MultiSelect_CSVOptions_final.gif
Header Line Sorting Control:
The header line is excluded from sorting by default, as shown in the demo. To alter the number of excluded lines, change HeaderLines=1 to your desired count in [userdir]\AppData\Roaming\Notepad++\plugins\config\MultiReplace.ini.
Regex Assistance for Numeric Sorting:
To prepare numbers for lexicographical sorting and later remove the added leading zeros, you may use the following regex patterns:
Purpose
Find Pattern
Replace With
Align Numbers with Leading Zeros (Decimal)
\b(\d*)\.(\d{2})
set(string.rep("0",9-string.len(string.format("%.2f", CAP1)))..string.format("%.2f", CAP1))
Align Numbers with Leading Zeros (Non-decimal)
\b(\d+)
set(string.rep("0",9-string.len(CAP1))..CAP1)
Remove Leading Zeros (Decimal)
\b0+(\d*\.\d+)
$1
Remove Leading Zeros (Non-decimal)
\b0+(\d*)
$1
Required Settings:
For “Align Numbers with Leading Zeros” operations:
Enable ‘Regex’
Enable ‘Use Variables’
For “Remove Leading Zeros” operations:
Enable ‘Regex’