Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re-setting NLS_LANG from C++/OCI app

Re-setting NLS_LANG from C++/OCI app

From: Pat Weber <pat_at_PROBLEM_WITH_INEWS_GATEWAY_FILE>
Date: 1997/05/29
Message-ID: <51d7cd$b2327.46@news.protocom.com>#1/1

Hello, If this is posted to the wrong oracle group, please let me know so that I may re-post.

I am running against OCI 7.3.

Here are the steps that I am following:

  1. Get my client's locale information
  2. putenv(NLS_LANG=appropriate string);
  3. olog()
  4. oopen()
  5. dutifully do my client's bidding
  6. oclose()
  7. ologof()
  8. wait for a new client to connect to me.
  9. if a new client connects, return to step 1.

Here's what's happening. The initial pass works perfectly. But if a subsequent client is running with different locale information that mandates a different NLS_LANG setting connects, the NLS_LANG variable is apparently not being re-read by Oracle. I make this assumption because I continue to get the data returned to me in the format that was proper for the initial setting of NLS_LANG.

My initial assumption that going to the lengths of calling ologof() prior to the re-setting of NLS_LANG would be sufficient was obviously in error.

One possible solution that was suggested to me was to submit an "ALTER SESSION" command after the resetting of NLS_LANG. This either isn't the answer or I didn't submit the proper ALTER SESSION command.

So, I guess my questions are:

Can this even be done? or is this an Oracle bug/deficiency?

If the answer is "Yes, this can be done", where in the world in the oracle documention should I have been able to find this info?

And/or

Does anyone know where in the documentation I can find a complete listing of ALTER SESSION options and parameters?

Thanks for any help or advice!

--
Pat Weber				pat_at_infoadvan.com
Information Advantage, Inc.		(612) 820-3864
7401 Metro Blvd, Suite 500
Edina, MN 55439
Received on Thu May 29 1997 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US