I use to pass data between *.java and *.jsp, since this is a MVC framework, it will go by the *.java first. so i used request.getSession().setAttribute("test", "01010101010") to save the value, and then in *.jsp, use request.getSession().getAttribute("test") to get value.
But it returns a strange string "682342348" all the time.
what's UP?????

Recommended Answers

All 4 Replies

Can you please provide code so we can try to find out what is going on?

The problem might be that there is 11 digits in you value. Regular integer values only takes 10, so you might get a memory loop or whatever it is called where the value gets to high, so it starts at the bottom and works it was up from -2,147,483,648, or the other way since you got a "0" in front. This usually refers to a negative value in machine code.

I've just tried this locally and I get the correct object from the session, so have to agree with peter_budo and request you post the code that you are deploying.

> The problem might be that there is 11 digits in you value

That shouldn't be a problem since he is storing a string.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.