org.mybatis.generator.exception.XMLParserException: XML Parser Error on line 12: 对实体 “useUnicode“ 的

org.mybatis.generator.exception.XMLParserException: XML Parser Error on line 12: 对实体 “useUnicode” 的引用必须以 ‘;’ 分隔符结尾。

在使用mybatis逆向工程时发生这个错误,将generatorConfig.xml中的URL中的&改为&emp;,就可以正常解析了。

 <!-- Mysql数据库连接的信息:驱动类、连接地址、用户名、密码 -->
        <jdbcConnection driverClass="com.mysql.jdbc.Driver"
                        connectionURL="jdbc:mysql://localhost:3306/management?serverTimezone=UTC&amp;\
  rewriteBatchedStatements=true&amp;useUnicode=true&amp;characterEncoding=utf8&amp;useSSL=false"
                        userId="****"
                        password="*****">
        </jdbcConnection>

猜你喜欢

转载自blog.csdn.net/Dong__Ni/article/details/107315028