| Author |
sql exception
|
Aarthi moorthy
Greenhorn
Joined: Feb 24, 2003
Posts: 7
|
|
hi all, I am updating a table with a set of values. My code is st.executeUpdate("update bulletinboard set (userid='"+s1+"',dateofposting='"+s2+"',messagetitle='"+s3+"',message='"+s4+"', administratorid='"+s5+"',typeofmessage='"+s6+"',expirydate='"+s7+"') where messageid=2"); I get an error as java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in query expression 'messageid='. Plz give me ur solutions.. Thanks in advance. regards, Aarthi.
|
 |
Kirtikumar Puthran
Ranch Hand
Joined: Mar 04, 2003
Posts: 37
|
|
Hi Aarthi, Try this : st.executeUpdate("update bulletinboard set (userid='"+s1+"',dateofposting='"+s2+"',messagetitle='"+s3+"',message='"+s4+"', administratorid='"+s5+"',typeofmessage='"+s6+"',expirydate='"+s7+"') where messageid='2'"); I have changed the where clause. Hope this helps. Rgds, Kirtikumar Puthran
|
Regards,<br />Kirti
|
 |
 |
|
|
subject: sql exception
|
|
|