mybatis 报The content of elements must consist of well-formed character data or markup. 语法格式错误
最近在写sql的时候 同时使用到了 >= 和 <= 之前只使用一个的时候 没有什么问题,今天同时使用到了两个,结果xml出现了The content of elements must consist of well-formed character data or markup.提示格式错误;
原来在xml中使用“<” ">" "&" 等一些这样的操作符时,xml会把它当成一个新的元素开始;
解决方法: 使用< ![CDATA[" 标记开始,以"]]> 包裹
在< ![CDATA[" 标记开始,以"]]> 里包裹的元素,在xml解析时会被解析器忽略
比如 >= 可以写成 <![CDATA[ >= ]]> ; <=等于可以写成 <![CDATA[ <= ]]>
记下次错,以防忘记
mybatis 报The content of elements must consist of well-formed character data or markup. 语法格式错误的更多相关文章
- Mybatis 异常: The content of elements must consist of well-formed character data or markup
原因很简单:在ibatis的配置文件中不能出现小于号(>) <delete id="deleteByPrimaryKey" parameterType=&quo ...
- Cause: org.xml.sax.SAXParseException: The content of elements must consist of well-formed character data or markup.
Caused by: org.apache.ibatis.builder.BuilderException: Error creating document instance. Cause: org ...
- ibatis配置文件中的XML解析错误The content of elements must consist of well-formed character data or markup.
在检查过所有的标签名都没有问题的情况下. xml中的小于号属于非法字符. SQL语句中则可能需要小于号,此时就需要用<![CDATA[ ]]>将小于号包裹,如此不会被xml解析器解析. ...
- ibatis动态sql配置启动时提示:The content of elements must consist of well-formed character data...
ibatis动态sql配置启动时提示:The content of elements must consist of well-formed character data... 2012-07-18 ...
- thymeleaf 解析html时,出现 SAXParseException: The content of elements must consist of well-formed characte
thymeleaf 解析html时,出现 SAXParseException: The content of elements must consist of well-formed characte ...
- ibatiS启动的异常 The content of elements must consist of well-formed character data or markup
ibatiS启动的异常 The content of elements must consist of well-formed character data or markup 配置的动态SQL语句里 ...
- The content of elements must consist of well-formed character data or markup
java 中使用dom4j解析含有特殊字符的xml文件出现了如题的错误 这个时候需要在特殊字符外面加上 <![CDATA[ /6169220648+20671/1>7+-47390045& ...
- mybatis报错Mapped Statements collection does not contain value for com.inter.IOper
首页 > 精品文库 > mybatis报错Mapped Statements collection does not contain value for com.inter.IOper m ...
- springboot 报错 Content type 'application/x-www-form-urlencoded;charset=UTF-8' not supported
开始 controller 方法写的是 @RequestMapping( value = "/add", method = RequestMethod.POST ) public ...
随机推荐
- 证明:对于一棵二叉树,若度为2的结点有n2个,叶子结点有n0个,则n0=n2+1
假设二叉树的0度,1度,2度结点数分别为\(n_0\),\(n_1\),\(n_2\),总节点数为\(T\) 则按照结点求和有 \[T=n_0+n_1+n_2 (1)\] 按照边求和,因为节点数等于边 ...
- LeetCode03 最长无重复子串
题目 给定一个字符串,找出不含有重复字符的最长子串的长度. 解答 刚开始以为只是一遍遍历后来的字符和前面一样便开始算新子串,给的案例都过了,但是卡在了"dvdf" 后来经过重重试验 ...
- Struts 2 执行流程 配置信息
Struts 2 执行流程 首先,浏览器访问,经过Filter,Filter从src/struts.xml中寻找命名空间和action的名字,获取action类,从方法中拿到返回值,接着从result ...
- shell脚本while read line的使用
#### 题目要求计算文档a.txt中每一行中出现的数字个数并且要计算一下整个文档中一共出现了几个数字.例如a.txt内容如下:12aa*lkjskdjalskdflkskdjflkjj我们脚本名字为 ...
- js判断输入的input内容是否为数字
有时候我们输入的input的内容需要判断一下是否是数字,所以为了更好的客户体验,在前端先处理一下: <input type="text" name="val&quo ...
- .NET Core WEB API中接口参数的模型绑定的理解
在.NET Core WEB API中参数的模型绑定方式有以下表格中的几种: 微软官方文档说明地址:https://docs.microsoft.com/zh-cn/aspnet/core/web-a ...
- python 数据分类汇总
STEP1: #读取数据: import pandas as pdinputfile_1 = "F:\\大论文实验\\数据处理\\贫困人口数据_2015.xlsx" data1 = ...
- pyhton课堂随笔-基本画图
%matplotlib inline import matplotlib as mpl import matplotlib.pyplot as plt import numpy as np impor ...
- STRANS一:简单的XML转换
心情不好,泥总把表妹微信给冰冰了,心塞... 1.简单的单层结构: <?sap.transform simple?> <tt:transform xmlns:tt="htt ...
- 突破防盗链Referrer
//引用的源码网站的js<script src="https://raw.githack.com/jpgerek/referrer-killer/master/referrer-kil ...