java 1.5 + sybase sql anywhere 9.0 with jConnect.... help pls
при попытке сделать UPDATE или INSERT данных состоящих из русских букв выкидывается EXEPTION
JZ006: Caught IOException: java.io.IOException: JZ0I6: An error occured converting UNICODE to the charset used by the server. Error message: java.io.CharConversionException: ы
залазим в sybase central, смотрим свойства базы:
CharSet: UTF8
Collation: UTF8
сервер запускается с помощью bat-файла с содержимым: dbeng9 database.db
я так понимаю что сервер по каким-то причинам работает в кодировке cp1251 ... но как её изменить..?
помогло свойство соединения
Properties props = new Properties();
props.put("charset", "cp1251");
вот тут нашёл следующее:
JZ0I6
An error occurred converting UNICODE to the charset used by the server. Error message: _____
Action: Choose a different character set code for the CHARSET connection property on the jConnect client that can support all the characters you need to send to the server. You may need to install a different character set on the server, too.
как изменить кодировку сервера (to install a different character set on the server)?
как изменить кодироку клиента (сhoose a different character set code for the CHARSET connection property on the jConnect)?
JZ006: Caught IOException: java.io.IOException: JZ0I6: An error occured converting UNICODE to the charset used by the server. Error message: java.io.CharConversionException: ы
залазим в sybase central, смотрим свойства базы:
CharSet: UTF8
Collation: UTF8
сервер запускается с помощью bat-файла с содержимым: dbeng9 database.db
я так понимаю что сервер по каким-то причинам работает в кодировке cp1251 ... но как её изменить..?
помогло свойство соединения
Properties props = new Properties();
props.put("charset", "cp1251");
вот тут нашёл следующее:
JZ0I6
An error occurred converting UNICODE to the charset used by the server. Error message: _____
Action: Choose a different character set code for the CHARSET connection property on the jConnect client that can support all the characters you need to send to the server. You may need to install a different character set on the server, too.
как изменить кодировку сервера (to install a different character set on the server)?
как изменить кодироку клиента (сhoose a different character set code for the CHARSET connection property on the jConnect)?
