Page 1 of 1

Column to new text file and back

Posted: Sun May 08, 2011 4:10 am
by Ronbot_1
Hello,
A work with large text coded files were each position in a line has distinctive meaning. The file is not csv.
I need to copy the content of 2 specific colums to a new file (preferably a csv, say e.g. tmp.csv) , use that in Excel to make changes and then insert these back into the same file, replacing the original content in those columns.

I have been able to select the correct lines and colums without any problem.

Restrict to lines matching [^04]
Copy columns:10 columns starting at column 85 copy to 15

but cannot export to a external file and then import the changes.

How can Texpipe help ?

Regards
Ron

Re: Column to new text file and back

Posted: Mon May 09, 2011 11:34 am
by DataMystic Support
Hi Ron,

You can use Filters\Special\Secondary output filter to send the output to a new file.

What changes do you need to make in Excel? You should be able to use Filters\Special\Script (VBScript,JScript...) to make any changes, perform calculations etc, or even search/replace filters inside the restriction.

Re: Column to new text file and back

Posted: Tue May 10, 2011 4:31 am
by Ronbot_1
DataMystic Support wrote:Hi Ron,

You can use Filters\Special\Secondary output filter to send the output to a new file.

What changes do you need to make in Excel? You should be able to use Filters\Special\Script (VBScript,JScript...) to make any changes, perform calculations etc, or even search/replace filters inside the restriction.
Thanks for the reply. I've used the above filter to output to a file. Now I have trouble getting the changed columns back into the original file (I can't find an ADD columns from file filter). Is there any other way ?

The Excel output is only temporary. I must be able to make random changes to specific parts. Once I get more acquinted I can start using the jscripts.

Regards
Ron

Re: Column to new text file and back

Posted: Tue May 10, 2011 9:01 am
by DataMystic Support
Hi Ron,

Your best bet is to output every line, not just matching ones, and then use the Filters\Add\Add text side-by-side to add the changes back in.

You will then need to Filters\Remove\Columns the original columns, and Filters\Special\Move columns/fields\Move columns into the right position.