一、该问题的重现步骤是什么?
1. 日期字段查询,按日期范围查询
2.
3.
二、你期待的结果是什么?实际看到的又是什么?
三、你正在使用的是什么产品,什么版本?在什么操作系统上?
四、请提供详细的错误堆栈信息,这很重要。
AND (bill_code LIKE ? AND create_time[] LIKE ?)
at org.apache.ibatis.exceptions.ExceptionFactory.wrapException(ExceptionFactory.java:30)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:149)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:140)
at sun.reflect.GeneratedMethodAccessor490.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:427)
... 110 more
Caused by: com.baomidou.mybatisplus.core.exceptions.MybatisPlusException: Failed to process, Error SQL: SELECT id,bill_code,out_time,tare,plan_weight,actual_weight,price,actual_money,car_name,cusomer_name,product_name,remarks,tenant_id,create_user,create_dept,create_time,update_user,update_time,status,is_deleted FROM mysoft_weightrecord
WHERE is_deleted=0
AND (bill_code LIKE ? AND create_time[] LIKE ?)
at com.baomidou.mybatisplus.core.toolkit.ExceptionUtils.mpe(ExceptionUtils.java:39)
at com.baomidou.mybatisplus.extension.parser.JsqlParserSupport.parserSingle(JsqlParserSupport.java:52)
at com.baomidou.mybatisplus.extension.plugins.inner.TenantLineInnerInterceptor.beforeQuery(TenantLineInnerInterceptor.java:70)
at com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor.intercept(MybatisPlusInterceptor.java:78)
at org.apache.ibatis.plugin.Plugin.invoke(Plugin.java:61)
at com.sun.proxy.$Proxy272.query(Unknown Source)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:147)
... 115 more
Caused by: net.sf.jsqlparser.parser.ParseException: Encountered unexpected token: "]" "]"
at line 4, column 39.
Was expecting one of:
"!"
"("
"+"
"-"
"?"
"@"
"@@"
"ACTION"
"ANY"
"BYTE"
"CASCADE"
"CASE"
"CAST"
"CHANGE"
"CHAR"
"CHARACTER"
"COLUMN"
"COLUMNS"
"COMMENT"
"COMMIT"
"CREATE"
"CURRENT"
"CYCLE"
"DESC"
"DESCRIBE"
"DISABLE"
"DIV"
"DO"
"DOUBLE"
"DUPLICATE"
"ENABLE"
"END"
"EXCLUDE"
"EXTRACT"
"FALSE"
"FIRST"
"FN"
"FOLLOWING"
"FORMAT"
"GROUP"
"GROUP_CONCAT"
"IF"
"INDEX"
"INSERT"
"INTERVAL"
"ISNULL"
"KEY"
"LAST"
"LEFT"
"LIMIT"
"MATERIALIZED"
"NEXTVAL"
"NO"
"NOLOCK"
"NOT"
"NULL"
"NULLS"
"OF"
"OFFSET"
"ON"
"OPEN"
"OPTIMIZE"
"ORDER"
"OVER"
"PARTITION"
"PATH"
"PERCENT"
"PRECISION"
"PRIMARY"
"PRIOR"
"PROCEDURE"
"PUBLIC"
"RANGE"
"READ"
"REPLACE"
"RIGHT"
"ROW"
"ROWS"
"SCHEMA"
"SEPARATOR"
"SEQUENCE"
"SESSION"
"SET"
"SIBLINGS"
"SIZE"
"START"
"TABLE"
"TABLES"
"TEMP"
"TEMPORARY"
"TO"
"TOP"
"TRUE"
"TRUNCATE"
"TYPE"
"UNSIGNED"
"VALIDATE"
"VALUE"
"VALUES"
"VIEW"
"XML"
"XMLSERIALIZE"
"ZONE"
"{d"
"{t"
"{ts"
"~"
at net.sf.jsqlparser.parser.CCJSqlParser.generateParseException(CCJSqlParser.java:26538)
at net.sf.jsqlparser.parser.CCJSqlParser.jj_consume_token(CCJSqlParser.java:26377)
at net.sf.jsqlparser.parser.CCJSqlParser.PrimaryExpression(CCJSqlParser.java:11012)
at net.sf.jsqlparser.parser.CCJSqlParser.BitwiseXor(CCJSqlParser.java:10671)
at net.sf.jsqlparser.parser.CCJSqlParser.MultiplicativeExpression(CCJSqlParser.java:10624)
at net.sf.jsqlparser.parser.CCJSqlParser.AdditiveExpression(CCJSqlParser.java:10587)
at net.sf.jsqlparser.parser.CCJSqlParser.BitwiseAndOr(CCJSqlParser.java:10533)
at net.sf.jsqlparser.parser.CCJSqlParser.ConcatExpression(CCJSqlParser.java:10509)
at net.sf.jsqlparser.parser.CCJSqlParser.SimpleExpression(CCJSqlParser.java:10495)
at net.sf.jsqlparser.parser.CCJSqlParser.PrimaryExpression(CCJSqlParser.java:11046)
at net.sf.jsqlparser.parser.CCJSqlParser.BitwiseXor(CCJSqlParser.java:10671)
at net.sf.jsqlparser.parser.CCJSqlParser.MultiplicativeExpression(CCJSqlParser.java:10624)
at net.sf.jsqlparser.parser.CCJSqlParser.AdditiveExpression(CCJSqlParser.java:10587)
at net.sf.jsqlparser.parser.CCJSqlParser.BitwiseAndOr(CCJSqlParser.java:10533)
at net.sf.jsqlparser.parser.CCJSqlParser.ConcatExpression(CCJSqlParser.java:10509)
at net.sf.jsqlparser.parser.CCJSqlParser.SimpleExpression(CCJSqlParser.java:10495)
at net.sf.jsqlparser.parser.CCJSqlParser.SQLCondition(CCJSqlParser.java:9195)
at net.sf.jsqlparser.parser.CCJSqlParser.Condition(CCJSqlParser.java:8697)
at net.sf.jsqlparser.parser.CCJSqlParser.AndExpression(CCJSqlParser.java:8498)
at net.sf.jsqlparser.parser.CCJSqlParser.OrExpression(CCJSqlParser.java:8400)
at net.sf.jsqlparser.parser.CCJSqlParser.AndExpression(CCJSqlParser.java:8530)
at net.sf.jsqlparser.parser.CCJSqlParser.OrExpression(CCJSqlParser.java:8400)
at net.sf.jsqlparser.parser.CCJSqlParser.Expression(CCJSqlParser.java:8371)
at net.sf.jsqlparser.parser.CCJSqlParser.WhereClause(CCJSqlParser.java:7284)
at net.sf.jsqlparser.parser.CCJSqlParser.PlainSelect(CCJSqlParser.java:4307)
at net.sf.jsqlparser.parser.CCJSqlParser.SetOperationList(CCJSqlParser.java:4496)
at net.sf.jsqlparser.parser.CCJSqlParser.SelectBody(CCJSqlParser.java:4163)
at net.sf.jsqlparser.parser.CCJSqlParser.Select(CCJSqlParser.java:4158)
at net.sf.jsqlparser.parser.CCJSqlParser.SingleStatement(CCJSqlParser.java:130)
at net.sf.jsqlparser.parser.CCJSqlParser.Statement(CCJSqlParser.java:81)
at net.sf.jsqlparser.parser.CCJSqlParserUtil.parseStatement(CCJSqlParserUtil.java:163)
at net.sf.jsqlparser.parser.CCJSqlParserUtil.parse(CCJSqlParserUtil.java:59)
at net.sf.jsqlparser.parser.CCJSqlParserUtil.parse(CCJSqlParserUtil.java:37)
at com.baomidou.mybatisplus.extension.parser.JsqlParserSupport.parserSingle(JsqlParserSupport.java:49)
五、若有更多详细信息,请在下面提供。
扫一扫访问 Blade技术社区 移动端