mysql- could not execute query是什么原因导致的啊?

问题描述

could not execute query是什么原因导致的啊?

There is no Action mapped for namespace / and action name LoginAction_login. - [unknown location]
at com.opensymphony.xwork2.DefaultActionProxy.prepare(DefaultActionProxy.java:177)
at org.apache.struts2.impl.StrutsActionProxy.prepare(StrutsActionProxy.java:61)
at org.apache.struts2.impl.StrutsActionProxyFactory.createActionProxy(StrutsActionProxyFactory.java:39)
at com.opensymphony.xwork2.DefaultActionProxyFactory.createActionProxy(DefaultActionProxyFactory.java:47)
at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:458)
at org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:77)
at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:76)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:96)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:852)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:619)
Hibernate:
select
administra0_.id as id0_,
administra0_.administrator_id as administ6_0_,
administra0_.email as email0_,
administra0_.name as name0_,
administra0_.password as password0_,
administra0_.realname as realname0_
from
Administrator administra0_
where
1=1
and (
lower(administra0_.name) like 'admin'
)
and administra0_.password='123456'
17:26:22,465 WARN org.hibernate.util.JDBCExceptionReporter:100 - SQL Error: 1054, SQLState: 42S22
17:26:22,466 ERROR org.hibernate.util.JDBCExceptionReporter:101 - Unknown column 'administra0_.administrator_id' in 'field list'
在控制台出现以下语句是什么意思
Hibernate:
select
administra0_.id as id0_,
administra0_.administrator_id as administ6_0_,
administra0_.email as email0_,
administra0_.name as name0_,
administra0_.password as password0_,
administra0_.realname as realname0_
from
Administrator administra0_
where
1=1
20:48:32,118 WARN org.hibernate.util.JDBCExceptionReporter:100 - SQL Error: 1054, SQLState: 42S22
20:48:32,126 ERROR org.hibernate.util.JDBCExceptionReporter:101 - Unknown column 'administra0_.administrator_id' in 'field list'
Hibernate:
select
administra0_.id as id0_,
administra0_.administrator_id as administ6_0_,
administra0_.email as email0_,
administra0_.name as name0_,
administra0_.password as password0_,
administra0_.realname as realname0_
from
Administrator administra0_
where
1=1
20:48:37,948 WARN org.hibernate.util.JDBCExceptionReporter:100 - SQL Error: 1054, SQLState: 42S22
20:48:37,949 ERROR org.hibernate.util.JDBCExceptionReporter:101 - Unknown column 'administra0_.administrator_id' in 'field list'

解决方案

here is no Action mapped for namespace / and action name LoginAction_login. - [unknown location]//未知的位置,是不是你路径写错了
like 'admin'//这个需不需要加%或者_
Unknown column 'administra0_.administrator_id' in 'field list'//未知的列

你根据打印的错误提示一个个找然后修改就可以了

如果回答对您有帮助,请采纳

解决方案二:

unknown的column,你的列名是不是用错了。

解决方案三:

mysql的代码执行有问题,可以贴出你的mysql部分的代码么?

时间: 2024-12-21 12:33:31

mysql- could not execute query是什么原因导致的啊?的相关文章

hibernate-Hibernate使用sql语句操作数据库时出现的异常could not execute query

问题描述 Hibernate使用sql语句操作数据库时出现的异常could not execute query 代码如下: HibernateUtil: public static int createSqlQuery(String sql Serializable... serializables) { Session session = null; Integer result = null; try { session = getSession(); session.beginTransa

java web-GenericJDBCException:could not execute query

问题描述 GenericJDBCException:could not execute query 各位大神,我修改了数据库的字段,然后重新用hibernate反向工程搭入项目然后部署运行报以下错误,用的是struts2和hibernate框架,感觉像是数据库的问题,请教各位大神指点! 解决方案 那张貌似看不清楚,看这个吧

java-org.hibernate.exception.SQLGrammarException: could not execute query

问题描述 org.hibernate.exception.SQLGrammarException: could not execute query 大神们,看看这maven项目的异常,登陆成功之后,就显示json返回格式异常,query也不能查找了 :[DEBUG] 10:51:35[120906] [ http-5555-3] [000-] [] [AccessControlAdvice] com.wisetop.wtp.core.svc.ServiceException: 按id查找应用系统

RDS for MySQL 错误 the table '/home/mysql/xxxx/xxxx/#tab_name' is full 的原因和处理

RDS for MySQL 错误 the table '/home/mysql/xxxx/xxxx/#tab_name' is full 的原因和处理   1. 出现这个错误信息的原因 2. 如何处理该错误信息 3. 如何判断查询是否使用内部临时表 在使用 RDS 的过程中,有时会碰到下面的出错信息: the table '/home/mysql/xxxx/xxxx/#tab_name' is full,比如: the table '/home/mysql/data3077/tmp/#sql_1

Mysql/MariaDB启动时处于进度条状态导致启动失败的原因及解决办法_mariadb

今天打开网站突然发现网站无法打开,后来通过SSH登陆服务器发现MARIADB数据库没有启动成功,再次启动还是无法成功启动,一直处于启动进度条,进度条结束后提示ERROR.查看日志出现以下错误: InnoDB: Unable to lock ./ibdata1, error: 11 后经调试发现是因为MariaDB数据库所在分区已经满了,造成无法启动. 只有将MariaDB数据库存放数据目录移动到另外一个磁盘份额比较大的分区或者将当前分配删除一些不必要的文件. 移动办法: 1.停掉mysql服务器

tomcat-登录的时候报空指针异常,以前从来没出现过。不清楚到底什么原因导致的。

问题描述 登录的时候报空指针异常,以前从来没出现过.不清楚到底什么原因导致的. 2015-1-26 19:34:04 org.apache.catalina.core.StandardWrapperValve invoke 严重: Servlet.service() for servlet default threw exception java.lang.NullPointerException at com.opensymphony.xwork2.util.LocalizedTextUtil

关于MYSQL 5.6 super_read_only和Event Scheduler冲突导致启动失败

关于MYSQL 5.6 super_read_only和Event Scheduler冲突导致启动失败 版本percona-server-5.6.22-72.0,这个版本肯定有这个问题 这个问题出现在线上我们将库设置为super_read_only后启动报错,整个MYSQLD CRASH掉 2017-04-23 01:15:46 22577 [ERROR] Event Scheduler: Failed to open table mysql.event 2017-04-23 01:15:46

记录asp.net网站是什么原因导致停止运行的代码

 这篇文章主要介绍了记录asp.net网站是什么原因导致停止运行的具体实现 记录网站是什么原因导致停止运行还是有必要的,下面是具体的实现方式.  代码如下: protected void Application_End(object sender, EventArgs e)  {  RecordEndReason();  }    /// <summary>  /// 记录网站停止运行原因  /// </summary>  protected void RecordEndReaso

qq邮箱-mutt + msmtp ,126邮箱发送成功,QQ邮箱发送失败,请问什么原因导致的失败?感谢

问题描述 mutt + msmtp ,126邮箱发送成功,QQ邮箱发送失败,请问什么原因导致的失败?感谢 我弄了一晚上都没弄好,关于认证.加密.端口什么的都试过无数次了 goolge到一篇帖子,通过抓包发现本应该被识别的部分数据被忽视了,导致步骤错位 (原贴:http://sjcatsoft.cnblogs.com/archive/2009/06/06/1497772.html) 请更明白其中原因的大神,能够精确指点一下 (我猜想sendmail或者postfix会不会存在类似的问题) 感谢~