0

Until not long ago, the NLS_CHARACTERSET and the NLS_LANG were both ISO88591. We deliver to production some scripts encoded in ISO88591.

Since they changed their NLS_LANG in utf8, they have a problem charging our ISO88591 scripts which seem to be normal because special characters are not recognized.

They would like the NLS_LANG to be utf8, but is there a way to change it (what is the command line?) to ISO8859 only when they are in charge of our scripts?

  • What OS are you using? – Marco Jun 6 '18 at 12:06
1

Depends on the OS. The NLS_LANG is just an environment variable that you need to set. This variable makes the SQL*Net to convert the character-set of the database into this character-set and reversed when sending it to the database.

In Linux you need to add the following line at the start of your script:

export NLS_LANG=AMERICAN_AMERICA.ISO8859

Perhaps you must change the AMERICAN_AMERICA into the value that you use.

  • yes it is linux...doing the export works in thesql plus session only ? some other people using sqlplus on the same server will have naturally NLS_LANG utf8? – mlwacosmos Jun 6 '18 at 12:28
  • This only works in the script. – Marco Jun 6 '18 at 12:59
  • it means you have to pu it in every script you send ? – mlwacosmos Jun 6 '18 at 13:01
  • Yes you must. Other solution is that you use a special user to run these scripts and put it in the .bash_profile of that user. – Marco Jun 6 '18 at 13:04
  • Correct character set name in for Oracle would be WE8ISO8859P1 – Wernfried Domscheit Jun 11 '18 at 7:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.