How to delete record by using servlet

Posted on 2005-04-11
Medium Priority
Last Modified: 2012-06-27
Dear Sir,

I have the problem with delete record, the message shows me that " HTTP 405 - Resource not allowed ".

I use jsp which pointed to servlet page, the following is my servlet code that i did: String sqlText="delete from tblPersonnel where id=8";

Please kindly correct my code if it is wrong, because i can not use the above code to delete record.

Question by:svannak
  • 2
LVL 35

Expert Comment

ID: 13751257
You're going to have to post more of your servlet code...

your code looks fine...so I guess there is another reason for the servlet failing...

Have you configured it right in web.xml?


Author Comment

ID: 13751476
I use jrun web server, I already one for select, update & insert database record and it works. Only the problem for delete.

LVL 35

Accepted Solution

TimYates earned 400 total points
ID: 13751488
You are going to have to post some more code...

Is it the same servlet that does all functions (update, select, insert, etc)?

Check that the servlet is returning the right values...

Check that this servlet is set up in web.xml the same as your others...

As I said, posting more code (the servlet, and the web.xml definition) would help...as then I may be able to see what you're doing wrong...


Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

"Day by day nothing changes but when u look back, everything is different". That quote precisely describes today’s digital era. For example, you may not have noticed the change, but Voice Search is now all around us.
Article by: Tammy
MySQLTuner is a script written in Perl that allows you to review a MySQL installation quickly and make adjustments to increase performance and stability. The current configuration variables and status data is retrieved and presented in a brief forma…
Integration Management Part 2
How can you see what you are working on when you want to see it while you to save a copy? Add a "Save As" icon to the Quick Access Toolbar, or QAT. That way, when you save a copy of a query, form, report, or other object you are modifying, you…
Suggested Courses

621 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question