Due to my inexperience with php, I can only guess.
I assumed that php db interface works like perl.
Perl uses a Interface called DBI + DBD:Oracle which itself (AFAIK)
uses the Oracle OCI library. Also, it uses the NLS_LANG variable
to determine what Language/character setting the client is using.
Java thin driver however does not use the NLS_LANG setting ....
AFAIK, it talks to the server and assumes that character setting.
Thus, you need to take into account two things:
* Determine what characterset the data being input is in. If I have a
UTF8 data which I try to insert in perl using a WE8ISO..
NLS_LANG setting, I might see garbled data being inserted.
* Determine how the php interface is inserting data .. i.e. does it
use the NLS_LANG?
To me it appears that either your data is not in WE8I... charset ...
or ... if php uses NLS_LANG .. the env variable is not set (which you
said was not the case .. i.e. it is set)
Also, What is the characterset of your database? WE8I.. or UTF8 .. or ...?
Maybe some php guru can comment on this?
> The WEb (Apache) User and the oracle user has the same environment
> variables. With both users, from sqlplus, I can insert and get words
> with ,,etc, but not from a php web page.
> Any idea?
> > I don't know php ... but you should understand that:
> > * Setting NLS_LANG for oracle user will set it for only that user.
> > * Thus you need to make sure that the web user has this same envioronment variable set.
> > Anurag
> > > Hello list
> > > I have installed oracle client 9.0.1 in my Linux box.
> > > my ~oracle/.bash_profile:
> > > umask 022
> > > if [ -f ~/.bashrc ]; then
> > > source ~/.bashrc
> > > fi
> > > ORACLE_BASE=/usr/local/oracle
> > > export ORACLE_BASE
> > > ORA_NLS33=/usr/local/oracle/product/9.0.1/ocommon/nls/admin/data
> > > export ORA_NLS33
> > > NLS_LANG=SPANISH_SPAIN.WE8ISO8859P1
> > > export NLS_LANG
> > > But when I insert data in the oracle DB server , from a form web (php)
> > > that contains the '?','','','','' and '' characteres, they don't
> > > appear well in the Server
> > > Is anything missing?
> > > Any missconfiguration?
> > > Thanks.
> > > Fernando