关键字导致mybatis的OGNL表达式异常

在做一个演示项目时,为了简便,我把表中审核人字段用shr。结果导致org.apache.ibatis.builder.BuilderException: Error evaluating expression 'shr != null'。这是因为shr字段与mybatis的OGNL表达式发生冲突

mybatis的OGNL包含一下字符

",",
"=",
"?",
"||",
"or",
"&&",
"and",
"|",
"bor",
"^",
"xor",
"&",
"band",
"==",
"eq",
"!=",
"neq",
"<",
"lt",
">",
"gt",
"<=",
"lte",
">=",
"gte",
"in",
"not",
"<<",
"shl",
">>",
"shr",
">>>",
"ushr",
"+",
"-",
"*",
"/",
"%",
"instanceof",
".",
"(",
"[",

posted on 2021-02-24 10:50  冯亮  阅读(516)  评论(0编辑  收藏  举报

导航