Linux Bash Programming

Discuss all aspects of programming here.

Moderator: The Mod Squad

Linux Bash Programming

Postby chrisostomos » Sat Mar 04, 2006 1:30 pm

Hi

I was wondering if anyone knows how to replace in a file all the single quotations by a space

I was trying the tr command but with no luck

tr -s "'"" " < filename.txt

Thanks
chrisostomos
Initiate
Initiate
 
Posts: 79
Joined: Fri Jan 23, 2004 11:13 pm

Postby chrisostomos » Sat Mar 04, 2006 1:55 pm

its ok i found the answer

sed -e s/\'/\ /g < filename.txt
chrisostomos
Initiate
Initiate
 
Posts: 79
Joined: Fri Jan 23, 2004 11:13 pm

Postby chrisostomos » Sat Mar 04, 2006 2:02 pm

another thing i was wondeing is how could i take the all the 17th cloumn in a file and then move it to the first?

Thanks
chrisostomos
Initiate
Initiate
 
Posts: 79
Joined: Fri Jan 23, 2004 11:13 pm


Return to Programming

Who is online

Users browsing this forum: No registered users and 0 guests