程序師世界是廣大編程愛好者互助、分享、學習的平台,程序師世界有你更精彩!
首頁
編程語言
C語言|JAVA編程
Python編程
網頁編程
ASP編程|PHP編程
JSP編程
數據庫知識
MYSQL數據庫|SqlServer數據庫
Oracle數據庫|DB2數據庫
 程式師世界 >> 編程語言 >> 更多編程語言 >> 編程綜合問答 >> exception-新手學hibernate簡單登錄遇到未知錯誤

exception-新手學hibernate簡單登錄遇到未知錯誤

編輯:編程綜合問答
新手學hibernate簡單登錄遇到未知錯誤

package com.gloomy.rigister.model;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;

@Entity
public class user {

private int id;
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
public int getId() {
    return id;
}

public void setId(int id) {
    this.id = id;
}
public String getUsername() {
    return username;
}
public void setUsername(String username) {
    this.username = username;
}
public String getPassword() {
    return password;
}
public void setPassword(String password) {
    this.password = password;
}
private String username;
private String password;

}
錯誤信息
嚴重: Developer Notification (set struts.devMode to false to disable this message):
Unexpected Exception caught setting 'passrword' on 'class com.gloomy.rigister.action.userAction: Error setting expression 'passrword' with value ['25', ]
九月 27, 2015 10:18:34 上午 com.opensymphony.xwork2.interceptor.ParametersInterceptor error
嚴重: Developer Notification (set struts.devMode to false to disable this message):
Unexpected Exception caught setting 'password1' on 'class com.gloomy.rigister.action.userAction: Error setting expression 'password1' with value ['25', ]
九月 27, 2015 10:18:34 上午 com.opensymphony.xwork2.interceptor.ParametersInterceptor error
嚴重: Developer Notification (set struts.devMode to false to disable this message):
Unexpected Exception caught setting 'username' on 'class com.gloomy.rigister.action.userAction: Error setting expression 'username' with value ['he', ]

最佳回答:


我自己粗心把index.jsp中form表單中的password寫成passrword了

  1. 上一頁:
  2. 下一頁:
Copyright © 程式師世界 All Rights Reserved