您的位置:首页 > Web前端

xml文件中配置JDBC源遇到问题 : The reference to entity "characterEncoding" must end with the ';' delimiter

2016-12-29 02:54 555 查看
数据源配置时加上编码转换格式后出问题了:

The reference to entity"characterEncoding" must end with the ';' delimiter

这个错误就是 context.xml中设置数据源链接URL的问题

<context-param>

<param-name>url</param-name>

<param-value>jdbc:mysql://localhost:3306/bookstore?useUnicode=true&characterEncoding=UTF-8</param-value>

</context-param>

正确的如下:

<context-param>

<param-name>url</param-name>

<param-value>jdbc:mysql://localhost:3306/bookstore?useUnicode=true&characterEncoding=UTF-8</param-value>

</context-param>

这大概是由xml文件中的编码规则决定要这么变换。

在xml文件中有以下几类字符要进行转义替换:

内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  hive xml
相关文章推荐