| От | Thomas Kellerer |
|---|---|
| Тема | Re: JDBC to load UTF8@psql to latin1@mysql |
| Дата | |
| Msg-id | kad433$c35$1@ger.gmane.org обсуждение исходный текст |
| Ответ на | Re: JDBC to load UTF8@psql to latin1@mysql (Emi Lu <emilu@encs.concordia.ca>) |
| Список | pgsql-general |
Emi Lu wrote on 13.12.2012 15:00: > >>> Is there a simple way to load UTF8 data in psql to mysql(with latin1 >>> encoding) through JDBC? >> >> All you need to do is to query the source database, then use >> ResultSet.getString() to obtain the data and use a PreparedStatement and >> PreparedStatement.setString() to insert/update the data on the target >> database. >> >> The JDBC drivers will handle all the conversion. >> Do NOT manually convert the data. >> >> getString() and setString() will do everything correctly. > > I am not using stmt directly but through Mybatis for all db transactions. > > So, this approach will not work. Then it's a problem of that MyBatis thing. Thomas
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера