0

When I connect with sqlplus (windows 7, cmd) to a oracle database and query with umlauts (ü, ö, ä) I don't get anything back.

I queried for the NLS_LANG and got following back:

AMERICAN_AMERICA.WE8ISO8859P1

The oracle database runs on a linux distribution. So I opened the cmd box and entered

set NLS_LANG=AMERICAN_AMERICA.WE8ISO8859P1

and repeated the query - once more without success. Then I got following hint:

set NLS_LANG=German_Germany.WE8PC850'

This worked - finally. But I want to use the query statement in joomla. And now I don't know how to handle with this problem. I use oci8 and oracle10g. Any ideas?

Thanks in advance.

Mladen
  • 99
  • 1
  • 12

2 Answers2

0

According to the Oracle docs you can set the NLS_LANG forever (rather than having to set it every time you connect) by running the 'setenv' command in Linux:

setenv NLS_LANG German_Germany.WE8PC850

Link: http://docs.oracle.com/cd/E12102_01/books/AnyInstAdm784/AnyInstAdmPreInstall18.html

This will only work of course if you have access to the server. If you do not, there may be some way of calling the 'set NLS_LANG=German_Germany.WE8PC850' after every time Joomla connects to the database, but I don't know anything about Joomla so I can't help you there!

user1578653
  • 4,888
  • 16
  • 46
  • 74
  • Remember that the XAMPP server is running on Windows and the oracle database, on which I haven't access, is running on Linux. – Mladen Feb 28 '14 at 09:27
0

I found the solution in a post from @ddallala. Here is the link: utf8_decode

utf8_decode($_POST['search_name_with_special_character'])

was the solution.

Community
  • 1
  • 1
Mladen
  • 99
  • 1
  • 12