![]() |
| ||
| I can't insert data into database Hi I have a difficulty in insertion data. I don't get any error message but it doesn't insert data to database. My code is below. Where am I wrong? <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" |
| ||
| Re: I can't insert data into database You posted in wrong section, check out our Web Development for JSP section (I already made request for post to be moved) Also in mean time you can have look at this post JSP database connectivity according to Model View Controller (MVC) Model 2 |
| ||
| Re: I can't insert data into database i'm so sorry as i was very new to this community and now what should i do shall i remove this thread and paste it somewhere else? and plz do solve my problem. Is my code correct or i should do any modifications?It's very urgent......thanks in advance |
| ||
| Re: I can't insert data into database Well syntactically your JSP page is correct, although the approach of firing queries directly from inside the JSP page (that too using SQL Statements constructed on the fly) is not only bad but dangerous. Also you need some brushing up on your concepts of HTML and Javascript. The <input> tags need to be nested inside a corresponding <form> tag, if you want the data from the <input> tag to be posted to the JSP page mentioned in the "action" attribute of <form> tag. Also I do not see any Javascript functions by the name of InsertZoneInfo(),UpdateZoneInfo() or DeleteZoneInfo() If you are using Firefox you could go to Tools ->Error Console to see the various Javascript errors or alternatively you could install the Firebug extension for more comprehensive debugging info. Anyways the situation as I see demands that you learn not only about JSP and MVC[1,2,3] but also about HTML and JavaScript right now. |
| ||
| Re: I can't insert data into database double check on database schema and tables and columns are they exactly what you have in the code? |
| ||
| Re: I can't insert data into database You can make two changes: 1: from oracle database homepage login as administrator then unlock the hr (may be it work) 2: try this url: to Connection con = DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe","hr","hr");hope this will works......... bye |
| All times are GMT -4. The time now is 10:24 am. |
Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC