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
Shell script help to eliminate files of todays date richM Shell Programming and Scripting 2 04-20-2009 04:40 AM
Combine fields and eliminate white space ski UNIX for Dummies Questions & Answers 2 07-25-2008 01:03 PM
Cannot redirect ouput????? minifish Shell Programming and Scripting 3 02-20-2008 12:15 PM
Eliminate variable checking in a script BMetelsky Shell Programming and Scripting 8 12-04-2007 10:59 AM
Red Hat - ouput capture juxtaman UNIX for Dummies Questions & Answers 3 04-10-2003 11:31 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-21-2009
rveri rveri is offline
Registered User
  
 

Join Date: Sep 2009
Posts: 12
Post script to eliminate left and right fields and to get the ouput.

Hi Experts,
I have a file as given below and want to filter out the filenames in it , by deleting left and right filds and to have the fllenames (There are spaces in the filename),

Code:
Sun Jan 11 11:20:10 2009 1 0 /home/output/file2311_recent.list user1 user2 0 done
Sun Jan 11 11:20:10 2009 1 0 /home/output/file2312 jan recent.list user1 user2 0 done
Sun Jan 11 11:20:10 2009 1 0 /home/output/Output2313 feb recent.text user1 user2 0 done

I want to eliminate first 7 field from left side , and 4 fields from right side , and to get the output . Is there anything available with scripting , sed awk ?



Output should be:

Code:
/home/output/file2311_recent.list
/home/output/file2312 jan recent.list 
/home/output/Output2313 feb recent.text
Thanks in advance,

Last edited by vgersh99; 10-21-2009 at 07:28 PM.. Reason: code tags, please.
 

Bookmarks

Tags
scripting, sed awk shell

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 12:11 AM.


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