LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 05-13-2004, 11:39 PM   #1
pantera
Member
 
Registered: May 2004
Posts: 80

Rep: Reputation: 15
awk/sed help


this is the 3rd line in a file
abc 10 20 30 50 90 30 hh 12
how to modify the fitth value(i.e. 50) using awk or sed??
 
Old 05-13-2004, 11:59 PM   #2
mousebubble
LQ Newbie
 
Registered: Feb 2004
Location: Ohio
Distribution: Ubuntu
Posts: 16

Rep: Reputation: 0
the quick and dirty way would be to do

awk '{print $1, $2, $3, $4, "NewValue", $6, $7, $8, $9}'
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
SED, AWK or PERL HELP embsupafly Programming 6 08-20-2005 09:07 PM
Sed & Awk hinetvenkat Linux - Software 4 05-30-2005 05:10 AM
awk and sed issues alaios Linux - General 11 03-24-2005 05:33 AM
sed or awk help requested tonyfreeman Programming 7 10-03-2004 12:23 AM
sed/awk problem player_2 Programming 9 08-26-2003 06:09 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:35 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration