You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
mysql> create table test_shard (id int(11) primary key,R_REGIONKEY float,R_NAME varchar(50),R_COMMENT varchar(50));
Query OK, 0 rows affected (0.03 sec)
mysql> insert into test_shard (id,R_REGIONKEY,R_NAME,R_COMMENT) values (1,1, 'a string','test001'),(3,3, 'another string','test003');
Query OK, 2 rows affected (0.01 sec)
mysql> select mytest.test_shard.R_NAME from test_shard;
ERROR 1064 (HY000): com.alibaba.druid.sql.ast.expr.SQLPropertyExpr cannot be cast to com.alibaba.druid.sql.ast.expr.SQLIdentifierExpr
log:
2017-09-19 15:56:29.090 WARN [BusinessExecutor1] (com.actiontech.dble.server.ServerConnection.executeException(ServerConnection.java:285)) - ServerConnection [id=5, schema=mytest, host=127.0.0.1, user=test,txIsolation=3, autocommit=true, schema=mytest]select mytest.test_shard.R_NAME from test_shard err:java.lang.ClassCastException: com.alibaba.druid.sql.ast.expr.SQLPropertyExpr cannot be cast to com.alibaba.druid.sql.ast.expr.SQLIdentifierExpr
java.lang.ClassCastException: com.alibaba.druid.sql.ast.expr.SQLPropertyExpr cannot be cast to com.alibaba.druid.sql.ast.expr.SQLIdentifierExpr
at com.actiontech.dble.plan.visitor.MySQLItemVisitor.endVisit(MySQLItemVisitor.java:431) ~[dble-2.17.08.0.jar:?]
at com.alibaba.druid.sql.ast.expr.SQLPropertyExpr.accept0(SQLPropertyExpr.java:71) ~[druid-1.0.31.jar:1.0.31]
at com.alibaba.druid.sql.ast.SQLObjectImpl.accept(SQLObjectImpl.java:41) ~[druid-1.0.31.jar:1.0.31]
at com.actiontech.dble.route.parser.druid.impl.DruidSelectParser.isSumFunc(DruidSelectParser.java:258) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.route.parser.druid.impl.DruidSelectParser.parseAggExprCommon(DruidSelectParser.java:216) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.route.parser.druid.impl.DruidSelectParser.parseAggGroupCommon(DruidSelectParser.java:306) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.route.parser.druid.impl.DruidSelectParser.parseOrderAggGroupMysql(DruidSelectParser.java:177) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.route.parser.druid.impl.DruidSelectParser.visitorParse(DruidSelectParser.java:113) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.route.parser.druid.impl.DefaultDruidParser.parser(DefaultDruidParser.java:47) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.route.util.RouterUtil.routeFromParser(RouterUtil.java:117) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.route.impl.DefaultRouteStrategy.routeNormalSqlWithAST(DefaultRouteStrategy.java:59) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.route.impl.AbstractRouteStrategy.route(AbstractRouteStrategy.java:45) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.route.RouteService.route(RouteService.java:105) ~[dble-2.17.08.0.jar:?]
at com.actiontech.dble.server.ServerConnection.routeEndExecuteSQL(ServerConnection.java:232) [dble-2.17.08.0.jar:?]
at com.actiontech.dble.server.ServerConnection.execute(ServerConnection.java:176) [dble-2.17.08.0.jar:?]
at com.actiontech.dble.server.handler.SelectHandler.handle(SelectHandler.java:96) [dble-2.17.08.0.jar:?]
at com.actiontech.dble.server.ServerQueryHandler.query(ServerQueryHandler.java:62) [dble-2.17.08.0.jar:?]
at com.actiontech.dble.net.FrontendConnection.query(FrontendConnection.java:299) [dble-2.17.08.0.jar:?]
at com.actiontech.dble.net.FrontendConnection.query(FrontendConnection.java:317) [dble-2.17.08.0.jar:?]
at com.actiontech.dble.net.handler.FrontendCommandHandler.handleData(FrontendCommandHandler.java:65) [dble-2.17.08.0.jar:?]
at com.actiontech.dble.net.handler.FrontendCommandHandler$1.run(FrontendCommandHandler.java:117) [dble-2.17.08.0.jar:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [?:1.7.0_05]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [?:1.7.0_05]
at java.lang.Thread.run(Thread.java:722) [?:1.7.0_05]
The text was updated successfully, but these errors were encountered:
steps:
log:
The text was updated successfully, but these errors were encountered: