The UNIX and Linux Forums  

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




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 11-20-2007
srikanthshastry srikanthshastry is offline
Registered User
  
 

Join Date: Nov 2007
Posts: 1
Please help problem in KSH

Hi All,

I have got a problem. I have written a Shell script which cuts some information from the file a and puts it in file b. But i get this error when i execute the shell script.
This is what i have written in the script.

#! /usr/bin
cd /test
ls $2 > a
cut -f 1 -d '.' a > b


When i try to execute this script with this command-->
./test.sh 100 Eagle.txt
i get this error -> cut: 0653-132 Cannot open a.

i know its a dumb doubt.Please help