Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

644.Advanced search and replace -- How to combine 2 lists of numbers into 2 columns repeatly?

User: editor -- 2010-10-31          << 643  645 >>
Hits: 1696
Type: Advanced search and replace   
Search all Advanced search and replace examples
Description:
I have two different list of hex number, the Fist list fixed hex number from 0000 - 11869F, the Second list fixed hex numbers 0000-270F.
How to keep numbers from the first list on the left and numbers form the second
list on the right?
Input Sample:
fist list
1234                 
2345b          
3456c
4567d
5678e
6789F

second list
0001
0002
Output Sample:
1234  0001
2345b  0002
3456c  0001
4567d  0002
5678e  0001
6789F  0002
Answer:
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
Assume first list is in file 'd:\1.txt', second list is in file 'd:\2.txt', steps:

1. ctrl-o open first file 1.txt
2. ctrl-h open 'replace' window
* set 'replace unit' to 'Line'
* set 'replace with pattern' to:

* click "Advanced" tab, fill "run following at the beginning of replace" as:

3. click "Replace", done!
4. ctrl-s save to file.

Note: 
* If your second file is not d:\\2.txt, please change the "import_values('d:\\2.txt','value')" in step 2 accordingly.

* Please use Replace Pioneer 2.58 or newer version.
Download Script:  scripts/644.rst.zip

Screenshot 1:  Replace_Window


Screenshot 2:  Replace_Advanced_Window


Similar Examples:
How to count the number of non-empty columns? (60%)
How to distribute 6 numbers into multiple lines randomly? (58%)
How to calculate the sum of the numbers in the same column? (57%)
How to batch split files into columns that separated by comma? (55%)
How to convert the data into a table with columns? (55%)
How to calculate the average of numbers of one column? (54%)
How to extract all lines in which first 2 columns are identical? (54%)
How to change the location of all numbers randomly? (54%)

Check Demo of Advanced search and replace
Keywords:
how to combine 2 lists  270f  lists  keep numbers  keys  combine  dictionary  diction  repeat  fixed  combine columns  replace lists  change to hex  fixed number  different columns  combine file  search and replace in file hex  file and replace hex