The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Advanced & Expert Users
Google UNIX.COM


UNIX for Advanced & Expert Users Advanced UNIX and Linux questions go here. Expert-to-Expert.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
convert the below perl sript to shell script mail2sant Shell Programming and Scripting 1 04-04-2008 10:36 AM
Shell Sript jazz8146 UNIX for Dummies Questions & Answers 3 01-11-2008 11:07 AM
Shell Sript - Spell Checker Assign ccfc1986 Shell Programming and Scripting 9 11-14-2007 09:52 PM
PGP Auto Respond queenie680 UNIX for Dummies Questions & Answers 1 11-08-2007 07:00 PM
Volcheck does not respond nikk UNIX for Advanced & Expert Users 2 01-10-2005 02:08 AM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 03-05-2008
Registered User
 

Join Date: Feb 2008
Posts: 9
Sript need, please respond

Hi
I am looking for the script which can move 1month old data from a TXT file.actully in this file data is appended on daily basis.pleasehalp me out.

Here is the file content :
$head abc.txt.
20070301130052,xxz.
20070307132111,cvasjchgjhcg
gacg
chjbgasjkchjk.
20070307133029,gcvashcvgjchklk.
20070308070017,hbcjkbgcjkhk.
20070308084700,hjcgjhcg.
20070308114137,kjcghjk.

$tail abc.txt
20080304113050,cgsjkchskjchskch.
20080304113053,cvbnsckhhkhcjs
cjksdhcklsjcl.
20080304120046,cvbsdcbksdhj
cvhbskcvnhsdkl
svjscvkmj.
20080304120048,vgsdjkv
vbsdkvhj
vnsdvlmj
vnm.


I want to remain only one month data in this file and cut other data and mv that into new location.


Thanks in advance
Reply With Quote
Forum Sponsor
  #2  
Old 03-05-2008
Tytalus's Avatar
Registered User
 

Join Date: Jun 2003
Location: Scotland
Posts: 290
This is the Third thread you've started for this question.

unix script to takes the old data from a TXT file and compress them into new file
Script needed

Please stop multiple posting - it is against the rules of the forum; and if you want assistance, it would be best to provide what you have come up with yourself and ask for pointers rather than attempting to get others to do all the work.
Reply With Quote
  #3  
Old 03-05-2008
Registered User
 

Join Date: Sep 2006
Posts: 55
anyways plz take care in posting duplicate threads.

Still then one suggestion. Why are you taking old data to a seperate file. Try to create new files based on date and append the data to that file.
Reply With Quote
  #4  
Old 03-05-2008
Registered User
 

Join Date: Feb 2008
Posts: 9
apologies for this, will take care in future
Actually i there are other processes related to the thid file which will affect if i created more than one file.
Thanks in advance
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 09:21 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0