Hi all..i am not able to insert the data into my data base. Below is my code
To find the error line is use System.out.println(). When i used that i was able to get output just before line 1. After line 1 i am not able to get any output.
But i am able to do my select statement properly. I am not able to find error in my insert statement. Please give me some suggestion.
Thanks Shailesh..... As you said i inserted printStackTrace(). So in my console i got the following error message
So from the message it is obvious that there is error in insert statement,but i am not able to knock off the error. Can u please check my insert statement and tell me whether there is any syntax error.
i mean that saying that there's only one correct aproach doesnt seem right to me: if you wanna make an insert with all fields you can simply say INSERT INTO table_name VALUES (value1, value2) , as that site's tutorial refers:
The INSERT INTO Statement The INSERT INTO statement is used to insert new rows into a table.
Syntax INSERT INTO table_name VALUES (value1, value2,....)
You can also specify the columns for which you want to insert data:
INSERT INTO table_name (column1, column2,...) VALUES (value1, value2,....)