I have a problem that I need to call a Perl script with parameters passing through and get the return value of the Perl script in AWK BEGIN. As shown below.
I have a Perl script util.pl
$res=`$exe_cmd`;
print $res;
Now in AWK BEGINblock (ksh) I need to call a script and get the return value.
BEGIN { print "in awk, application type is " type;
} \
{call per script here;}
How do I call a Perl script parameter with a parameter and get the return value $res?
res = util.pl a b c;
source
share