lealone / Lealone

比 MySQL 和 MongoDB 快10倍的 OLTP 关系数据库和文档数据库
Other
2.48k stars 520 forks source link

MySQL客户端执行SQL查询报Lost connection to MySQL server during query #216

Open bluegitter opened 11 months ago

bluegitter commented 11 months ago

服务端运行日志

java -jar lealone-6.0.0-SNAPSHOT.jar Lealone version: 6.0.0-SNAPSHOT Use default config Base dir: /Users/yanfei/Downloads/lealone_data Init storage engines: 3 ms Init transaction engines: 36 ms Init sql engines: 4 ms Init protocol server engines: 10 ms Init lealone database: 102 ms TcpServer started, host: 127.0.0.1, port: 9210 MongoServer started, host: 127.0.0.1, port: 27017 MySQLServer started, host: 127.0.0.1, port: 3306 PgServer started, host: 127.0.0.1, port: 5432 Total time: 466 ms (Load config: 3 ms, Init: 220 ms, Start: 243 ms) Exit with Ctrl+C Failed to prepare statement: select count() from pet org.lealone.common.exceptions.JdbcSQLException: Table "PET" not found; SQL statement: select count() from pet [42102-0] at org.lealone.common.exceptions.DbException.getJdbcSQLException(DbException.java:342) at org.lealone.common.exceptions.DbException.get(DbException.java:173) at org.lealone.common.exceptions.DbException.get(DbException.java:150) at org.lealone.sql.SQLParserBase.readTableOrView(SQLParserBase.java:5361) at org.lealone.sql.SQLParserBase.readTableFilter(SQLParserBase.java:1797) at org.lealone.sql.SQLParserBase.parseSelectSimpleFromPart(SQLParserBase.java:1723) at org.lealone.sql.SQLParserBase.parseSelectSimple(SQLParserBase.java:1539) at org.lealone.sql.SQLParserBase.parseSelectSub(SQLParserBase.java:1508) at org.lealone.sql.SQLParserBase.parseSelectUnion(SQLParserBase.java:1478) at org.lealone.sql.SQLParserBase.parseSelect(SQLParserBase.java:1466) at org.lealone.sql.SQLParserBase.parseStatement(SQLParserBase.java:455) at org.lealone.sql.SQLParserBase.parse(SQLParserBase.java:327) at org.lealone.sql.SQLParserBase.parse(SQLParserBase.java:285) at org.lealone.sql.SQLParserBase.parse(SQLParserBase.java:1) at org.lealone.db.session.ServerSession.prepareStatement(ServerSession.java:476) at org.lealone.plugins.mysql.server.MySQLServerConnection.prepareStatement(MySQLServerConnection.java:186) at org.lealone.plugins.mysql.server.MySQLServerConnection.executeStatement(MySQLServerConnection.java:205) at org.lealone.plugins.mysql.server.handler.CommandPacketHandler.handle(CommandPacketHandler.java:37) at org.lealone.plugins.mysql.server.MySQLServerConnection.handle(MySQLServerConnection.java:388) at org.lealone.net.nio.NioEventLoop.read(NioEventLoop.java:275) at org.lealone.net.nio.NioEventLoop.handleSelectedKeys(NioEventLoop.java:492) at org.lealone.net.NetScheduler.runEventLoop(NetScheduler.java:62) at org.lealone.server.scheduler.GlobalScheduler.run(GlobalScheduler.java:70) at java.lang.Thread.run(Thread.java:748) Failed to prepare statement: select count(*) from pet

客户端日志 mysql --no-beep -h 127.0.0.1 -P 3306 -u root Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 12 Server version: 5.7.35 Lealone-6.0.0-SNAPSHOT Community Server - SSPL

Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> select count(*) from pet; ERROR 2013 (HY000): Lost connection to MySQL server during query

codefollower commented 11 months ago

pet 表不存在