thanks chris! now it's working. I just put UTF-16 because i got following error in my xml-viewer: Character conversion error: "Malformed UTF-8 char -- is an XML encoding declaration missing?" (line number may be too low). SqlMapConfig.xml I created now a new file and put all my staff into and then it worked with UTF-8. Maybe I got some UTF-16 characters by copying from a tutorial. BTW, how did you saw the BOM?
Chris Lamey wrote: > > BTW, if you change the file's encoding from UTF-16 to UTF-8, you will > definitely need to get rid of the first two bytes. > > On Tue, 2007-07-24 at 11:42 -0600, Chris Lamey wrote: >> Hello, >> >> Is the file really UTF-16 and if so, is your jvm default encoding >> UTF-16? >> >> I cut and paste your file into one on my filesystem and saw a BOM before >> the first line. My guess is that the xml parser is choking on that. >> You either need to set your jvm default encoding correctly >> (-Dfile.encoding=UTF-16) so the jvm handles the BOM correctly or you >> need to change the encoding attribute in the file from UTF-16 to UTF-8. >> You could also try removing the first two bytes in the file, but then >> the file loses it's byte order marking. >> >> Cheers, >> Chris >> >> On Tue, 2007-07-24 at 10:14 -0700, coolfire wrote: >> > <?xml version="1.0" encoding="UTF-16" ?> >> > >> > <!DOCTYPE sqlMapConfig >> > PUBLIC "-//ibatis.apache.org//DTD SQL Map Config 2.0//EN" >> > "http://ibatis.apache.org/dtd/sql-map-config-2.dtd"> >> > >> > >> > >> > <sqlMapConfig> >> > >> > <transactionManager type="JDBC"> >> > <dataSource type="SIMPLE"> >> > <property name="JDBC.Driver" >> > value="com.mysql.jdbc.Driver"/> >> > <property name="JDBC.ConnectionURL" >> > value="jdbc:mysql://87.xxx.xx.xxx:1111/mySchema"/> >> > <property name="JDBC.Username" value="xxx"/> >> > <property name="JDBC.Password" value="xxx"/> >> > </dataSource> >> > </transactionManager> >> > >> > </sqlMapConfig> > > -- View this message in context: http://www.nabble.com/jUnit-test%2C-NodeletException-tf4134769.html#a11770055 Sent from the iBATIS - User - Java mailing list archive at Nabble.com.