Here is short script that will print all the .csv formatted files in your current directory, then prompt you for the file to convert and the name to give the tab delimited file. Finally it will perform the conversion
#!/usr/bin/perl # convert comma seperated file to tab delimited use strict; use warnings; system ("clear"); system ("ls *.csv"); print "\n"; print 'What is the comma seperated file you need to convert? '; chomp (my $csv_file = <> ); print 'What shall I name the new file? '; chomp (my $tabd_file = <> ); system ("< $csv_file tr \",\" \"\t\" > $tabd_file"); exit;
In reply to Re: Convert CSV file to TAB delimited
by Anonymous Monk
in thread Convert CSV file to TAB delimited
by TCM
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |