Please keep discussions on the mailing list rather than replying to
anyone directly, so the archives are complete.
In this case, you've isolated your problem to the database read/write
phase, which means it's not a Struts issue. You'll need to look again
at your database configuration and whatever middleware you're using
to communicate with it (e.g. JDBC, Hibernate). The specifics will
depend on your database backend, the middleware you're using and your
own persistence code and configuration.
L.
On 23-Jan-08, at 12:27 PM, [EMAIL PROTECTED] wrote:
Laurie Harper wrote:
wessam wrote:
i'm using struts 1.1, oracle 10g environment
i'm facing a problem that i can't save special characters as
"ẻ, €" from
the
page to database correctly though i used all the possible ways to
set the
encoding to utf-8
[...]
the point is the the characters reaches the action class corectly
but
when i
save to datbase an retrieve again it's viewed corrupted in the page
You've partially narrowed down the problem, which is good; now you
need
to narrow it down the rest of the way:
- is the data written to the database correctly? (try verifying
outside
or Struts)
- is the data retrieved from the database correctly in your action?
In other words, you need to determine if the problem is with the
save to
or restore from the database, or whether the problem is with
displaying the data from Struts.
My guess would be that it's the save/retrieve, since you didn't
mention
anything you'd done to ensure communication with the database was
preserving correct character encoding, in which case it would be
outside
the scope of Struts.
L.
when i debug .. i see that the insert query string reaches to
business layer correct "insert into test (testcoulmn) values
('€')", but when i execute the query i look to database table and
see it inserted corrupted to database
but one of my team told me not to depend on seeing the character in
database as in another project data was inserted to datbase as
"???" but retrieving correctly to the page !!
when i retrieve from database to view the data on the .jsp page,
the character is retrieved corrupted to the action class
i tried encoding the data retrieved from database to utf-8 again
before setting in in the formBean to avoid that database encoding
isn't utf-8 but it also didn't work !!!
any other solutions i missed ??
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Quoted from:
http://www.nabble.com/struts-request-encoding-to-utf-8-problem-
tp15041079p15046261.html
--
Laurie Harper
Open Source advocate, Java geek: http://www.holoweb.net/laurie
Founder, Zotech Software: http://www.zotechsoftware.com/
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]