The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 06-27-2005
gopskrish gopskrish is offline
Registered User
 

Join Date: Jun 2005
Posts: 26
Problem while using Sed command

I want to write the output of From_Date_Parm and To_Date_Parm to the target file. I want to write a script by passing the filename.
In my case the file is TransactionParams


I tried it through command line.

noofdays=TransactionParams




sed "s/From_Date_Parm.*$/From_Date_Parm=${now}/g" ./"$noofdays">./"$noofdays"\1\"
When i do this it is reading TransactionParams and writing it into TransactionParams1 file

But when i issue the next statement

sed "s/To_Date_Parm.*$/To_Date_Parm=${nows}/g" ./"$noofdays"\1\>/data01/et2/et2/CTI_London/IAM/metadata/"$noofdays"
it is giving following error message


Can't open ./TransactionParams1>/data01/et2/et2/CTI_London/IAM/metadata/TransactionParams

Let me know where the problem is.


cheers,
gops
Reply With Quote
Forum Sponsor