User: editor -- 2009-05-20 << 333 335 >> |
Hits: 4584 |
Type: Text merge |
Search all Text merge examples |
Description: |
I want to sort two data sets of fundamental stocks values, two spreadsheets of data, each with two columns of data imputed from two txt files. The data are not sequential and the sort desired produces a data txt output file for a third spreadsheet, which aligns the data sets. |
Input Sample: |
SHEET 1 (imput as txt file) A x B x C x D x E x F x G x Sheet 2 (imput as txt file) A x B x D x F x H x J x C x |
Output Sample: |
SHEET 3 A x A x B x B x C x C x D x D x E x ..... F x F x G x .... ..... H x ..... ..... ..... J x |
Answer: |
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps. |
The solution is to merge the 2nd column of two files base on the value of 1st column, and do a sort operation at last. Detailed procedures: 1. join the two txt files into one file, with one blank line between two files: A x B x C x D x E x F x G x <here is one blank line> A x B x D x F x H x J x C x 2. ctrl-o open the text file prepared in step 1. 3. ctrl-h open 'replace' dialog * set 'Replace Unit' to 'Line' * set 'Replace Scope' to 'Paragraph' ** click "Advanced" page * set "Run following at the beginning of replace" to: * set "Run following for each matched unit" to: * set "Insert End Text" to: 4. Click "Replace", done! |
Download Script: scripts/334.rst.zip |
Screenshot 1: Replace_Window |
Screenshot 2: Replace_Advanced_Window |