mysql数据库导入,没有数据,缓存报错

发布于 2021-11-27 08:42:30 字数 9448 浏览 801 评论 1

@红薯 你好,想跟你请教个问题:

严重: DLOG_VelocityServlet: 127.0.0.1 => ERROR:Unknown Velocity Error,url=http://localhost:8080/(Mon Nov 16 14:36:06 CST 2015)
org.hibernate.exception.SQLGrammarException: could not execute query
    at org.hibernate.exception.SQLStateConverter.convert(Unknown Source)
    at org.hibernate.exception.JDBCExceptionHelper.convert(Unknown Source)
    at org.hibernate.loader.Loader.doList(Unknown Source)
    at org.hibernate.loader.Loader.listUsingQueryCache(Unknown Source)
    at org.hibernate.loader.Loader.list(Unknown Source)
    at org.hibernate.loader.hql.QueryLoader.list(Unknown Source)
    at org.hibernate.hql.ast.QueryTranslatorImpl.list(Unknown Source)
    at org.hibernate.engine.query.HQLQueryPlan.performList(Unknown Source)
    at org.hibernate.impl.SessionImpl.list(Unknown Source)
    at org.hibernate.impl.QueryImpl.list(Unknown Source)
    at com.liusoft.dlog4j.dao.DAO.executeNamedQueryCacheable(DAO.java:455)
    at com.liusoft.dlog4j.dao.SiteDAO.listNewestSites(SiteDAO.java:165)
    at com.liusoft.dlog4j.velocity.DLOG_Home_VelocityTool.list_newest_sites(DLOG_Home_VelocityTool.java:196)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:295)
    at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:245)
    at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:203)
    at org.apache.velocity.runtime.parser.node.ASTReference.value(ASTReference.java:419)
    at org.apache.velocity.runtime.parser.node.ASTExpression.value(ASTExpression.java:73)
    at org.apache.velocity.runtime.parser.node.ASTSetDirective.render(ASTSetDirective.java:125)
    at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    at org.apache.velocity.runtime.directive.Parse.render(Parse.java:224)
    at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:170)
    at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74)
    at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:107)
    at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:194)
    at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:170)
    at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    at org.apache.velocity.runtime.directive.Parse.render(Parse.java:224)
    at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:170)
    at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74)
    at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:107)
    at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74)
    at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:107)
    at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    at org.apache.velocity.Template.merge(Template.java:254)
    at org.apache.velocity.tools.view.servlet.VelocityLayoutServlet.mergeTemplate(VelocityLayoutServlet.java:224)
    at org.apache.velocity.tools.view.servlet.VelocityViewServlet.doRequest(VelocityViewServlet.java:551)
    at com.liusoft.dlog4j.servlet.DLOG_VelocityServlet.doRequest(DLOG_VelocityServlet.java:107)
    at org.apache.velocity.tools.view.servlet.VelocityViewServlet.doGet(VelocityViewServlet.java:507)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:620)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at com.liusoft.dlog4j.servlet.DLOG_HomeFilter.doFilter(DLOG_HomeFilter.java:121)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at com.liusoft.dlog4j.servlet.DLOG_HibernateFilter.doFilter(DLOG_HibernateFilter.java:76)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:501)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)
    at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1040)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:607)
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:313)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:745)
Caused by: com.mysql.jdbc.exceptions.MySQLSyntaxErrorException: Unknown column 'sitebean0_.friend_status' in 'field list'
    at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:936)
    at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2941)
    at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1623)
    at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1715)
    at com.mysql.jdbc.Connection.execSQL(Connection.java:3249)
    at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:1268)
    at com.mysql.jdbc.PreparedStatement.executeQuery(PreparedStatement.java:1403)
    at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:93)
    at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:93)
    at org.hibernate.jdbc.AbstractBatcher.getResultSet(Unknown Source)
    at org.hibernate.loader.Loader.getResultSet(Unknown Source)
    at org.hibernate.loader.Loader.doQuery(Unknown Source)
    at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Unknown Source)
    ... 72 more


如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

百思不得你姐 2021-11-28 23:50:01

你拿到的数据好像有问题,给 dlog_site 表增加一个 friend_status 字段,类型是 tinyint

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文