Oracle NLS_LANG bug

When you want to use the Oracle Client for 10g on Windows and your computer uses the Swiss German Region and Language options, you will stumble across the following error when trying to connect to a database with Enterprise Manager:

Error occurred at recursive SQL level 1

Now what? It turns out that this is Oracle Bug 4598613: ORA-2248 from 10.2/10.1.0.5 client with NLS_LANG set to territory SWITZERLAND. Metalink has this to say:

ORA-604 / ORA-2248 occurs when NLS_LANG is set to 
FRENCH_SWITZERLAND.WE8ISO8859P15 on the client side , 
or a similar string using territory SWITZERLAND.
eg: GERMAN_SWITZERLAND

Solution

Set your NLS_LANG to something else than GERMAN_SWITZERLAND. For example:

set NLS_LANG=AMERICAN_AMERICA.WE8MSWIN1252

To make the change persistent, edit the following Registry key:

My Computer\HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\KEY_%ClientHomeName%\NLS_LANG

Hello world

My name is Simon Krenger, I am a Technical Account Manager (TAM) at Red Hat. I advise our customers in using Kubernetes, Containers, Linux and Open Source.

Elsewhere

  1. GitHub
  2. LinkedIn
  3. GitLab