Re: Fwd: Problem to get UTF8-CSV-File

Bill Ward <[email protected]>
Newsgroups gmane.comp.lang.perl.modules.dbi.general
Message-ID <CAKGT8Wp5c-Epnn_eVbsjNhfHcuvV6ZgS4skroJdm9L=cKTZoHA@mail.gmail.com>
On Fri, Dec 23, 2011 at 3:08 AM, Charles Jardine <[email protected]> wrote:

> On 22/12/11 20:40, Bill Ward wrote:
>
>> Agreed. Any Oracle initialization environment variables need to be set
>> before your Perl script starts. Another approach is to set them and then
>> re-exec() from within the script ... though be careful to avoid infinitely
>> re-execing the same script!
>>
>
> This is not correct. With the script as written, no Oracle related code
> is executed until connect time, so enviroment variables which are
> interpreted
> by Oracle can be set any time before the first connect.
>
> On the other hand, variables interpreted by the run-time loader, such as
> LD_LIBRARY_PATH, must be set before perl itself is loaded. So, re-execing
> is necessary for a change to LD_LIBRARY_PATH, but not, but not for a
> change of NLS_LANG.
>

Ah yes, this is what I was thinking of.... and often when loading Oracle
you have to make sure LD_LIBRARY_PATH is set properly to the Oracle
location. My apologies.

To make sure that the NLS_LANG (and things like ORACLE_HOME and TWO_TASK as
well) is set properly, it should suffice to load them in a BEGIN block or
via a 'use' statement that loads your own configuration module, prior to
loading DBD::Oracle.

-- 
Check out my LEGO blog at http://www.brickpile.com
Follow/friend me: facebook.com/billward • flickr.com/photos/billward •
twitter.com/williamward
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.