in reply to exporting environment variable to KSH

You need to set up the perl script so that it prints the desired value of the variable to STDOUT (with a line feed), and then assign the output of the perl script to the variable using back-ticks, like so:
$ FOO=`perl_script` $ export FOO
So, if "perl_script" consists of:
print "BAR\n"
Then, after you have run the two shell commands above, you can see the new value:
$ echo $FOO BAR
There is no other way. The perl script always runs as a sub-process, and any changes to %ENV within the script are simply scrapped when that sub-process terminates -- you cannot "export" an environment variable to a parent process; you can only provide a string value, which a parent shell can then use in a variable assignment.