Re: Help for Unix text file processing

2001-06-08 Thread Dave Morgan
Hi Jared, You are a kinder DBA than I. It's good to see that constulting attitude developing :) Dave Jared wrote . > But if I want to conserve the carriage return > Then change the script from '\n' to '\r\n' Jared -- Dave Morgan DBA, Cybersurf Office: 403 777 2000 ext 2

Re: Help for Unix text file processing

2001-06-07 Thread Jared Still
12:36 > À : Multiple recipients of list ORACLE-L > Objet : Re: Help for Unix text file processing > > > > Do it with Perl. If you don't know it, it's > time to learn. > > This script will do it: > > #!/usr/bin/perl -pw > > chomp; > next if

RE: Help for Unix text file processing

2001-06-07 Thread ALEMU Abiy
But if I want to conserve the carriage return -Message d'origine- De : Jared Still [mailto:[EMAIL PROTECTED]] Envoyé : jeudi 7 juin 2001 12:36 À : Multiple recipients of list ORACLE-L Objet : Re: Help for Unix text file processing Do it with Perl. If you don't know it, it

Re: Help for Unix text file processing

2001-06-07 Thread Jared Still
Do it with Perl. If you don't know it, it's time to learn. This script will do it: #!/usr/bin/perl -pw chomp; next if /^\s+$/; $_ =~ s/^\s+(.*)$/$1\n/; run as my_script file_to_fix.txt > fixed_file.txt Jared On Wednesday 06 June 2001 07:55, you wrote: > > Hey all, > > > > I am looking f

Re: Help for Unix text file processing

2001-06-06 Thread Diana_Duncan
Here are some sed commands that do what you want -- in the [] brackets, there is a space and a tab. $ cat removeblanks.sed /^[ ]*$/d s/^[]*// s/[ ]*$// Here's a test file. $ cat test.txt This is a real line, the lines above are a carriage return, a tab and spaces.

RE: Help for Unix text file processing

2001-06-06 Thread Kevin Lange
Look into using sed. It was made for that kind of thing. -Original Message- Sent: Wednesday, June 06, 2001 9:56 AM To: Multiple recipients of list ORACLE-L > Hey all, > > I am looking for some commands like ( grep, egrep, sed etc) to do the > following on a Unix box. > > 1. Command t