JDBC character encoding

前端 未结 4 1361
陌清茗
陌清茗 2020-11-29 03:18

I have a Java Web application running on GlassFish 3 and JPA (EclipseLink) on MySQL. The problem I\'m facing is that if I\'m saving entities to the database with the u

4条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-11-29 03:38

    I solved it with the following: I used the GlassFish admin interface to add this property to my connection pool's settings:

    characterEncoding = UTF-8

提交回复
热议问题