Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

1401.Advanced search and replace -- How to sort specified items descendingly in each line?

User: Dilip -- 2017-08-21          << 1400  1402 >>
Hits: 543
Type: Advanced search and replace   
Search all Advanced search and replace examples
Description:
In a line (not new line), sort according to descending order the tags in a line
by the numbers found in them
Input Sample:
<num>1</num><num>90</num><num>70</num><num>69</num>
<num>5</num><num>92</num><num>70</num><num>69</num>
Output Sample:
<num>90</num><num>70</num><num>69</num><num>1</num>
<num>92</num><num>70</num><num>69</num><num>5</num>
Answer:
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
1. ctrl-o open text file
2. ctrl-h open 'replace' dialogue
* set 'replace unit' to 'Line'
* set 'replace with pattern' to:

3. click 'advanced' tab, set 'run following for each matched unit' to:

4. click 'replace', done.

Screenshot 1:  Replace_Window


Screenshot 2:  Replace_Advanced_Window


Similar Examples:
How to sort the text file by the date at the beginning of each line? (67%)
How to add a specified value to the sequence number in each line? (63%)
How to count the number of specified part in each line? (62%)
How to sort the numbers in each line by the descending order in a text file? (59%)
How to list all specific terms that appearing in a text file? (58%)
How to batch split file delimitered by first dash in each line? (57%)
How to sort the text by the number of specific word in each line? (57%)
How to sort a text file by the length of text in each line? (57%)

Check Demo of Advanced search and replace
Keywords:
descending  pop  desc  found  tags  tag  acc  order  tem  sort  sort numbers in text file  replace tags  line order  order line  search replace sort  line numbers  numbers line  sort line