hello I am facing one problem while connecting to OARCLE database through SERVLETS using JDBC:ODBC Bridge. When I try to insert somthing to the database from the HTML forms. the statement for insertion is: "INSERT INTO M_COMPLAINTS VALUES (complaintno, name, Rollno, email, machineno, pdate, pdescription)"; where all the values are of string type retrieved from a HTML Form. the ERROR is : java.sql.SQLException: [Microsoft][ODBC driver for Oracle][Oracle]ORA-00984: column not allowed here at java.lang.
The problem with yours is that you have not mentioned the column name and the corresponding values. Also remember that the values for string should be in single quotes. Sample is shown below String value = "somevalue" ; "Insert into test ( colname ) values ( '" + value + "') " If you are not able to understand this, just go in for prepared statement. That is very simple and cool to use. Good Luck.
Joined: Jul 07, 2001
Thank You Yusuf for your prompt and useful reply. shivangi
Joined: Jun 23, 2001
I will be glad if you could let me know if you have solved the problem.
Originally posted by shivangi mathur: Thank You Yusuf for your prompt and useful reply. shivangi