问题:
测试myBatis的动态SQL的时候,控制台提示我出现了:Lexical error at line 1, column 20. Encountered: "\uff01" (65281), after : "" 的错误
原因:
在<if test="sex !=null and sex != ''">and sex=#{sex}</if>中 sex != ''使用了中文的 !,因此引发了错误。
测试myBatis的动态SQL的时候,控制台提示我出现了:Lexical error at line 1, column 20. Encountered: "\uff01" (65281), after : "" 的错误
在<if test="sex !=null and sex != ''">and sex=#{sex}</if>中 sex != ''使用了中文的 !,因此引发了错误。