| Author |
DB2 error in Linux - Unexpected Token code=-104 and status=42601
|
Raj Metha
Greenhorn
Joined: Aug 04, 2004
Posts: 2
|
|
Hi all db2 gurus, I am very new to db2. I am doing a java project which updates db2 using jdbc. Ok my update command will be like UPDATE TbNme set acsright = ?, set userid =?, set dte =? where grp=? and acs=? I will create a PreparedStatement and send the parameters. When executing i am getting db2exception :[IBM][CLI Driver][DB@] SQL0104N An Unexpected token "USERID" was found following "". Expected "=". code :-104 and status = 42601. Anybody can help me. Thanks in advance.
|
 |
Jeanne Boyarsky
internet detective
Marshal
Joined: May 26, 2003
Posts: 26192
|
|
Raj, You can only have one "set" keyword in the query. Try: UPDATE TbNme set acsright = ?, userid =?, dte =? where grp=? and acs=?
|
[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
|
 |
Stefan Wagner
Ranch Hand
Joined: Jun 02, 2003
Posts: 1923
|
|
I'm used to: Hi Jeanne, that happens, because I first had to start the database, to test my expection, which produced a new question, which I wrote first... [ October 12, 2004: Message edited by: Stefan Wagner ]
|
http://home.arcor.de/hirnstrom/bewerbung
|
 |
 |
|
|
subject: DB2 error in Linux - Unexpected Token code=-104 and status=42601
|
|
|