Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

395.Advanced search and replace -- How to convert database file into "|" delimitered file?

User: Rongjia Zhang -- 2010-01-16          << 394  396 >>
Hits: 396
Type: Advanced search and replace   
Search all Advanced search and replace examples
Description:
I want to extract some words in a text file, which is downloaded from the database of our library by clicking 'File','Save as'. And then I hope it can be converted into tab delimited text. Since the plain text conclues , ; . So I hope the delimted tab could be | So it can be easily imported to Excel or Access.
There're also tabs (such as between Evidence and from) in the downloaded text file. Those tabs should be deleted in advance, I think. Thank you very much!

Input Sample:
Title:Is the Division of Labor Limited by the Extent of the Market?: Evidence
from the Chemical Industry
Author:Arora, Ashish; Vogt, William B.; Yoon, Ji Woong
Author Affiliation:Duke U; RAND Corp, Pittsburgh, PA; Kyung Hee U
Publication Date:October 2009
Output Sample:
Is the Division of Labor Limited by the Extent of the Market?: Evidence from the Chemical Industry|Arora, Ashish; Vogt, William B.; Yoon, Ji Woong|Duke U; RAND Corp, Pittsburgh, PA; Kyung Hee U Publication|October 2009
Answer:
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
Assume your text format is:
*****:111<tab key>111
*****:222<tab key>2222
*****:3333333
*****:44444444444
*****:5555<tab key>5555
*****:6666<tab key>66666
*****:7777777777
*****:88888
...
1. Firstly, you need to convert text to following format:
111111
2222222
3333333
44444444444
55555555
666666666
7777777777
88888
Procedures:
(1) ctrl-o open source text file
(2) ctrl-h open 'replace' dialog
* set Replace Unit" to "Chars"
* set "Replace Scope" to "Line"
* fill "Search for Pattern" to:

* fill "Replace with Pattern" to:

(3) click "Replace", done!
2. Secondly, group every 4 lines, and convert it to "|" delimitered text:
111111|2222222|3333333|44444444444
55555555|666666666|7777777777|88888
....
(4) ctrl-h open 'Replace' dialog again
(5) "set Unit Number filter" to:

(6) set "Search for Pattern" to 

(7) set "Replace with Pattern" to

(8) click 'Replace', done!

!4<4> means not 4,8,12,...
Download Script:  scripts/395.rst.zip

Screenshot 1:  Replace_Window


Screenshot 2:  Replace_Window


Similar Examples:
How to convert the text from hex to decimal in a file? (60%)
How to convert the daily data into a weekly data in many text files? (58%)
How to join every 20 emails into one group that delimitered by semicolon? (57%)
How to convert the date in a text file into GMT(Greenwich Mean Time)? (57%)
How to convert Hexidecimal IP addresses in text file into decimal format? (57%)
How to convert IP addresses in text file into Hexidecimal format? (57%)
How to convert the text from decimal to hex in a file? (57%)
How to convert the data into a table with columns? (57%)

Check Demo of Advanced search and replace
Keywords:
tab delimited  delimited  tabs  access  database  abs  excel  group  key  acc  convert to plain text format  extract lines from text file by filter  extract every  group lines  between lines  extract between  replace between words  replace with a group