Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Hi, all Scripting professional.
Q. I have written script1.sh and calling script2.sh in
script1.sh file using bash shell as interpreter and my log
in shell also bash shell.My code like
Script1

#!/bin/bash
echo "My script2 call"
. script2.sh

Here script2.sh file run successfully but when I have
changed my interpreter bash to ksh like #!/bin/ksh
Error are comming script2.sh command not found. Guid me how
to call other script in our main script.

Answer Posted / deep

instead of

. script2.sh

Just try

sh script2.sh

It will Run

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is shell scripting?

988


write a shell script to check the failed jobs?

4352


What is option in shell script?

955


What is a scripting language simple definition?

1022


Is shell scripting easy to learn?

960


Is shell a scripting language?

951


What are the four fundamental components of every file system on linux?

1619


Why is used in shell scripting?

936


What is the significance of $#?

1017


What are "c" and "b" permission fields of a file?

970


How important is shell scripting?

983


What will happen to my current process when I execute a command using exec?

977


Can we run shell script in windows?

1058


What is sed in shell script?

978


What is a shell script in windows?

1022