illegal XML characters have to be replaced by entity references:
< < less than
> > greater than
& & ampersand
' ' apostrophe
" " quotation mark
or use the CDATA section.
Everything inside a CDATA section is ignored by the parser.
If your text contains a lot of "<" or "&" characters - like program code often does - the XML element can be defined as a CDATA section.
A CDATA section starts with "<![CDATA[" and ends with "]]>"
your connect string inside the jboss.jcml should look like this:
I encountered a strange problem and need your help.
I inserted a record in mySQL database by an EntityBean.Then when I querid it out it appeared mess.But when I restarted the jboss server,the data queried out appeared normal.
I think it may be that the jboss server get data from different place.The first time it get data from the instance pool,then when the server restarted,it get data from database.But in these two situations the data have different encoding.The first time it have the encoding of iso-8859-1(database default encoding),the second time it have the encoding of gb2312(local encoding).I have changed the charsetEncoding to iso-8859-1 in the file jboss.jcml according to your reply.But the problem still happened.
I don't know how to deal with this problem,could you please help me?
My platform is Win2k(Chinese) + jboss-2.4.4 + mySQL-3.23.47.
Thanks in advance.