java - jdbc code to update informations in a mysql table -
i have code in java-eclipse update informations in table mysql values in selected row of table didnt update after running function.for example want replace value "b" inested of "a" in column "username" please me :(
a first value b value want replace username name of 1 column code:
public void change("username","a","b") throws sqlexception{ prs=connect.preparestatement( "update user0 set " +s1+ "='" +s3+ "' '" +s1+ "'='" + s2+"'"); prs.execute(); }// end of function change
that shouldn't compile, syntax wrong:
public void change(string username, string a, string b) throws sqlexception{...}
Comments
Post a Comment