Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 93689 invoked from network); 23 Jan 2010 22:21:14 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 23 Jan 2010 22:21:14 -0000 Received: (qmail 69494 invoked by uid 500); 23 Jan 2010 22:21:13 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 69464 invoked by uid 500); 23 Jan 2010 22:21:13 -0000 Mailing-List: contact user-java-help@ibatis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user-java@ibatis.apache.org Delivered-To: mailing list user-java@ibatis.apache.org Received: (qmail 69456 invoked by uid 99); 23 Jan 2010 22:21:13 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 23 Jan 2010 22:21:13 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of lists@nabble.com designates 216.139.236.158 as permitted sender) Received: from [216.139.236.158] (HELO kuber.nabble.com) (216.139.236.158) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 23 Jan 2010 22:21:04 +0000 Received: from isper.nabble.com ([192.168.236.156]) by kuber.nabble.com with esmtp (Exim 4.63) (envelope-from ) id 1NYoLT-0004B0-2a for user-java@ibatis.apache.org; Sat, 23 Jan 2010 14:20:43 -0800 Message-ID: <27290482.post@talk.nabble.com> Date: Sat, 23 Jan 2010 14:20:43 -0800 (PST) From: StevenF To: user-java@ibatis.apache.org Subject: RE: insert going wrong after going from Sybase to MySQL In-Reply-To: <50CA25BD6EEA954FA592C097399942E31A75E3C4@CM1.wis.local> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Nabble-From: steven@web2.filipowicz.com References: <27274795.post@talk.nabble.com> <387831.54754.qm@web25901.mail.ukl.yahoo.com> <27280982.post@talk.nabble.com> <50CA25BD6EEA954FA592C097399942E31A75E3C4@CM1.wis.local> X-Virus-Checked: Checked by ClamAV on apache.org Hi Guys, Still no luck here. I have this, but doesn't work: ---------------------------- select last_insert_id() as value INSERT INTO Chesser (login, password, firstName, lastName, credits) values (#login#, #password#, #firstName#, #lastName#, #credits#) ---------------------------- Also tried: ---------------------------- select last_insert_id() as value INSERT INTO Chesser (login, password, firstName, lastName, credits) values (#login#, #password#, #firstName#, #lastName#, #credits#) --------------------------- This gives an error: SqlMapClient operation; uncategorized SQLException for SQL []; SQL state [null]; error code [0]; Insert statements cannot be executed as a query.; nested exception is java.sql.SQLException: Insert statements cannot be executed as a query. What is the difference between ? Thanks for the help!! Niels Beekman-2 wrote: > > Your XML is simply invalid, use an editor that supports DTD validation. > The selectKey element can only be used inside select elements. > > I also think that resultClass="java.lang.Long" is obsolete, and should > be removed. > > Niels > > > -- View this message in context: http://old.nabble.com/insert-going-wrong-after-going-from-Sybase-to-MySQL-tp27274795p27290482.html Sent from the iBATIS - User - Java mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: user-java-unsubscribe@ibatis.apache.org For additional commands, e-mail: user-java-help@ibatis.apache.org