change date stamp in a flat file
Posted on 2006-04-12
I have a flat file which has columns to be exported to a oracle table, this flat file has inside date format in the form of 2006-02-01 and 2006-02-28, I wanted to change every line that has this date format (could be any day during the month of feb) to start date as 2006-02-01 and 2006-02-07 since I want to restrict data being copied to just 7 days.
This was a problem to do manually since the file is large and also the start and end dates can be any date between 01 to 28 for the month of february.
Is there any way to do this using command line commands. Unix on which I am trying is LINUX.