Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Unknown Error in JSTL I guess.

 
Philip Zac
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I got this error. I was trying to save email. but the Database shows Null..
What does this error means???


ERROR [btpool0-1] ParametersInterceptor.setParameters(204) | ParametersInterceptor - [setParameters]: Unexpected Exception caught setting 'webAgent.email_id' on 'class com.trailsindia.webreservation.webapp.action.WebAgentAction: Error setting expression 'webAgent.email_id' with value '[Ljava.lang.String;@101bb2c'

Thanks
Philip
 
sudhir nim
Ranch Hand
Posts: 212
Eclipse IDE Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you have corresponding getter and setter in class ?
 
Philip Zac
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have the getter and setter in the model class.

Even if I put the getter and setter in the Action class.

the result will be the same.

Thanks
philip
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
on 'class com.trailsindia.webreservation.webapp.action.WebAgentAction:


This doesn't look like a JSTL error to me.
Look at the WebAgentAction class to see what it's expecting.
 
Philip Zac
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello all,
this is the WebAgentAction class. i dont see any error with it. There is a getter and setter for email in the WebAgent class. So I do not know what is wrong with it. Even if I tried to save the email address using the JSTL save button. there is a Null in the database for email. So it's pretty confusing...



public class WebAgentAction extends BaseAction {

private GenericManager<WebAgent, Long> webAgentManager;
private List webAgents;
private WebAgent webAgent;
private Long id;




public void setWebAgentManager(GenericManager<WebAgent, Long> webAgentManager) {
this.webAgentManager = webAgentManager;
}

public List getWebAgents() {
return webAgents;
}

public String list() {
webAgents = webAgentManager.getAll();
return SUCCESS;
}


public void setId(Long id) {
this.id = id;
}


public WebAgent getWebAgent() {
return webAgent;
}

public void setWebAgent(WebAgent webAgent) {
this.webAgent = webAgent;
}





public String delete() {
webAgentManager.remove(webAgent.getId());
saveMessage(getText("webAgent.deleted"));

return SUCCESS;
}

public String edit() {
if (id != null) {
webAgent = webAgentManager.get(id);
} else {
webAgent = new WebAgent();
}

return SUCCESS;
}

public String save() throws Exception {
if (cancel != null) {
return "cancel";
}

if (delete != null) {
return delete();
}

boolean isNew = (webAgent.getId() == null);

webAgent = webAgentManager.save(webAgent);
log.debug("1111111111111111111111111111" + webAgent);

String key = (isNew) ? "webAgent.added" : "webAgent.updated";
saveMessage(getText(key));

if (!isNew) {
return INPUT;
} else {
return SUCCESS;
}
}


}


anyway, Thanks.
Philip
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64631
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please be sure to use UBB code tags when posting code to the forums. Unformatted code is extermely hard to read and many people that might be able to help you will just move along. Please read this for more information.

You can go back and change your post to add code tags by clicking the .
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic