| Author |
"Error: 500 java/sql/Savepoint " what is this?
|
Sandeep Chhabra
Ranch Hand
Joined: Aug 28, 2005
Posts: 340
|
|
I am using J2EE and trying to access a table called DiagnosticCenter in the Database Pharma in MySQL. But I am getting this error..! what could be the possible reason? Thanks for you kind help
|
Regards<br />Sandy<br />[SCJP 5.0 - 75%]<br />[SCWCD 1.4 - 85%]<br />------------------<br />Tiger, Tiger burning bright,<br />Like a geek who works all night,<br />What new-fangled bit or byte,<br />Could ease the hacker's weary plight?
|
 |
Archies Gomes
Ranch Hand
Joined: Jun 19, 2005
Posts: 34
|
|
Hi Sandeep , For what reason I dont understand the error isnt visible to me and for noone perhaps...It would be really better if you pasted the error too. I havent worked on my-sql but yeah i think its somewhat like Oracle....so assuming that it too takes quotes around it to insert string you can try with the follwing, Note the single quotes ...as you are trying to enter a string so i think the column is too a string in your database or if its a integer ...probably you will have to remove the quotes and use Integer.parseInt(id);
|
 |
Sandeep Chhabra
Ranch Hand
Joined: Aug 28, 2005
Posts: 340
|
|
My JSP Page only shows : Error: 500 java/sql/Savepoint and you are right that it requires quotes to insert string...but it works if you have to insert an int in the int field.. (By the way that code works fine when Running with a class instead of jsp).
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56209
|
|
|
Moving to the JDBC forum as this isn't a question on JSP.
|
[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
|
 |
Maximilian Xavier Stocker
Ranch Hand
Joined: Sep 20, 2005
Posts: 381
|
|
Errr I don't see anything using a Savepoint in this code. Could you post a stack trace or something? The only thing I see that I don't like is that you don't specify the columns you are inserting values for. If this is anything but a one column table that could well be the problem. But I don't see how that would have a SavePoint error. I kind of wonder if your JSP environment is 1.3 or earlier. Is that possible. It could be possible that your driver is checking for a save point or something and pre 1.4 there was no such thing as java.sql.Savepoint so I suppose that might be it. A stack trace or more detail about the error would really help. I understand why this question was moved... but it might be more of a JSP setup question really.
|
 |
Maximilian Xavier Stocker
Ranch Hand
Joined: Sep 20, 2005
Posts: 381
|
|
Sandeep, I think you need to identify your JSP environment. Particularly what java version it is.
|
 |
Sandeep Chhabra
Ranch Hand
Joined: Aug 28, 2005
Posts: 340
|
|
my J2EE is installed in : D:\j2sdkee1.2.1\ I think it should be 1.2... and I am using JDK1.5 does this matters...? [ November 09, 2005: Message edited by: Sandeep Chhabra ]
|
 |
Maximilian Xavier Stocker
Ranch Hand
Joined: Sep 20, 2005
Posts: 381
|
|
Originally posted by Sandeep Chhabra: my J2EE is installed in : D:\j2sdkee1.2.1\ I think it should be 1.2... and I am using JDK1.5 does this matters...? [ November 09, 2005: Message edited by: Sandeep Chhabra ]
Yes it matters. java.sql.Savepoint does not exist until 1.4. I think you need to upgrade your runtime... or look for a driver version that is 1.2 compatible. I think upgrading your runtime is a better choice.
|
 |
Prashant Jain
Greenhorn
Joined: Aug 19, 2004
Posts: 29
|
|
yes the explanation about runtime is correct. I faced a similar problem with Oracle. I had to get the correct driver for the jdk i was using. I hope it helps.
|
 |
Sandeep Chhabra
Ranch Hand
Joined: Aug 28, 2005
Posts: 340
|
|
upgraded my application server to j2ee1.4 and almost lost every thing. I am a newbie in j2ee and was trying learn... anyways..new appserver is installed in D:\Sun\AppServer and there is no public_html folder...which used to be there in j2ee1.2 could you please tell me how should I run my JSP page now? Thanks a lot
|
 |
Maximilian Xavier Stocker
Ranch Hand
Joined: Sep 20, 2005
Posts: 381
|
|
Originally posted by Sandeep Chhabra: upgraded my application server to j2ee1.4 and almost lost every thing. I am a newbie in j2ee and was trying learn... anyways..new appserver is installed in D:\Sun\AppServer and there is no public_html folder...which used to be there in j2ee1.2 could you please tell me how should I run my JSP page now? Thanks a lot
This question is new question and should be asked in the JSP forum. I would help you if I could but I have no idea. Sorry.
|
 |
 |
|
|
subject: "Error: 500 java/sql/Savepoint " what is this?
|
|
|