The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
sed problem - delete all lines until a match on 2 lines plelie2 Shell Programming and Scripting 11 09-18-2009 05:25 AM
How to delete lines in a file that have duplicates or derive the lines that aper once necroman08 Shell Programming and Scripting 3 07-17-2009 06:07 AM
Grep and delete lines except the lines with strings vj8436 Shell Programming and Scripting 14 04-17-2009 12:25 PM
How to delete first 5 lines and last five lines in all text files ragavendran31 Shell Programming and Scripting 10 02-21-2008 07:58 AM
delete blank lines or lines with spaces only vascobrito UNIX for Dummies Questions & Answers 3 01-13-2004 07:36 AM

 
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1 (permalink)  
Old 10-03-2009
lost.identity lost.identity is offline
Registered User
  
 

Join Date: Oct 2009
Location: Cambridge, UK
Posts: 1
Unhappy Sed to delete lines that with the following

Hi,

I'm very new to Sed and I have a very large file that contains data in the following way

Code:
(*064) 1    4  10
(*064) simulation time =  0.12000E-05
(*064) 1    2  10
(*064) 1    3  10
Essentially what I want to do it delete every line that starts with
Code:
'(*064) 1'
I tried the following,

Code:
sed '/^(*064) 1/d' filename
But this doesn't work. I'm not sure whether this is because the start of the line contains special characters (forward bracket and the asterix) or whether there is a space before 1.

How would I do it?

Thanks
 

Bookmarks

Tags
sed

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 07:08 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0