Click here to Skip to main content
15,886,873 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
statement.execute("INSERT INTO tablename " + "VALUES (field1.getText(),field2.getText(),field3.getText())");

or

stmt.execute("INSERT INTO " + tableName + " VALUES (" + field1.getText() + ",'" + field2.getText() + "','" + field3.getText() +"')");



can we give such arguments to sql query or only number or "string" is used...
Posted
Updated 20-Mar-12 6:42am
v5

1 solution

Did you have tried anything?

SQL
UPDATE your_table
SET password = value
WHERE email = "xyz@" AND pass = "asdfg"


I don't know where you stuck with. Have a look at the following for more details.

http://www.w3schools.com/sql/sql_update.asp[^]
 
Share this answer
 
Comments
Akshayy Tikekarr 17-Mar-12 7:40am    
thank u sir and sorry WHERE & SET did struck to my mind. the same can be used to select required password....
CodingLover 17-Mar-12 23:37pm    
You are welcome!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900