LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 05-24-2013, 07:01 AM   #1
flacchy
LQ Newbie
 
Registered: May 2013
Posts: 17

Rep: Reputation: Disabled
replace 1:N:0 with 2:N:0 in a txt file


Hi,

I have a txt file with lines like this:
'@D3P26HQ1:180:c0yj8acxx:4:1101:1303:2205 1:N:0:TGACCA'

and I have to replace the part with 1:N:0 with 2:N:0

I have been trying to use this command
>> sed -i 's/1:N:0/2:N:0/g' Read1_ID_2.txt

but it won't work...

What else can I try?

F.
 
Old 05-24-2013, 07:20 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
What do you mean by but it won't work...?

It does work on my side when using your example.
 
Old 05-24-2013, 08:16 AM   #3
flacchy
LQ Newbie
 
Registered: May 2013
Posts: 17

Original Poster
Rep: Reputation: Disabled
The program got stuck... So I'll just try and wait maybe will just take longer time the file is 1 gb
Thnak you for checking
F.
 
  


Reply



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
[SOLVED] how to replace text in txt file using unix command lwang3rock Linux - Newbie 3 02-14-2013 12:22 PM
[SOLVED] Replace Characters in txt file struct Linux - Newbie 4 11-07-2010 01:28 PM
Help Strip / Remove attachments (Replace with TXT file if Possible) Vince0000 Linux - General 2 09-17-2010 06:46 PM
Does anyone know of a bash script can search & replace txt in a file. jimwelc Linux - Newbie 6 09-15-2008 12:13 AM
How do i change spaces inside a txt file, and replace space with backslash \? repolona Linux - Newbie 1 05-24-2006 05:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 04:58 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