Hi,

seems you're in un*x shell, so ">" is a valid redirection for perl script's 
output.
if you also want to redirect the stderr then do:
perl my.pl > out.txt 2>&1

 redirect STDOUT in perl script itself:

open HD,">","out.txt" or die $!;
open STDOUT,">&HD" or die $!;


HTH.


On Nov 17, 2009, Subhashini <subhashinibasavar...@gmail.com> wrote: 

is there a possiblity how i cud run a perl script and redirect the output

example my file name is  my.pl

Could i do perl my.pl > out.txt

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to