Return-Path: Delivered-To: apmail-openjpa-dev-archive@www.apache.org Received: (qmail 58093 invoked from network); 7 Sep 2007 20:28:04 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 7 Sep 2007 20:28:04 -0000 Received: (qmail 3951 invoked by uid 500); 7 Sep 2007 20:27:58 -0000 Delivered-To: apmail-openjpa-dev-archive@openjpa.apache.org Received: (qmail 3924 invoked by uid 500); 7 Sep 2007 20:27:57 -0000 Mailing-List: contact dev-help@openjpa.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@openjpa.apache.org Delivered-To: mailing list dev@openjpa.apache.org Received: (qmail 3915 invoked by uid 99); 7 Sep 2007 20:27:57 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 07 Sep 2007 13:27:57 -0700 X-ASF-Spam-Status: No, hits=2.0 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of kwsutter@gmail.com designates 209.85.146.176 as permitted sender) Received: from [209.85.146.176] (HELO wa-out-1112.google.com) (209.85.146.176) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 07 Sep 2007 20:27:54 +0000 Received: by wa-out-1112.google.com with SMTP id m28so707787wag for ; Fri, 07 Sep 2007 13:27:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; bh=9AlEd8zdYPLc3p16FMCppPIMUSFdqHroM5Fv5OWlUKc=; b=e5JkE7rpIYR6HvNP5DkjeEaE1H/WD6jJlKfSzBBsWkcsI4sok3ZqJqc/XsljcSG/HBKnGoVznn+IGOs0F+8xu8qwVEugDzH23DnXfMmHMCHm4JSQ7OGgvjlhs1Ihy2QMAl/xq7opp1sE/gi6vF8X60ghdPJm79SNootKWU7nj94= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=EJG/7OLfnrFfmFRcwHnfvgoVijFlIhEaUxupd4tO/I+H6220/mcbDYthSo7nVjd5ANKTSxCx6mZ9x4e6va5vNTfxlCT+6CvQGty8eCsSAnIDq0KrEniXeKC8eoSgwzv5sZewVNkHZJaJYVeJn9AlcbpCqzOxLQQq+frAzgnLOL8= Received: by 10.115.17.1 with SMTP id u1mr1264454wai.1189196853037; Fri, 07 Sep 2007 13:27:33 -0700 (PDT) Received: by 10.114.75.15 with HTTP; Fri, 7 Sep 2007 13:27:32 -0700 (PDT) Message-ID: <89c0c52c0709071327n71e66a09m570c0bb03e65da51@mail.gmail.com> Date: Fri, 7 Sep 2007 15:27:32 -0500 From: "Kevin Sutter" To: dev@openjpa.apache.org Subject: Re: DB2 and "FOR UPDATE OF" clause In-Reply-To: <7262f25e0709061409o1b43b153r6675e4c8cf7aa0e@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_3628_30888589.1189196853033" References: <7262f25e0709061328r221c4eaav9fa0aaa2750a2c97@mail.gmail.com> <7262f25e0709061409o1b43b153r6675e4c8cf7aa0e@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_3628_30888589.1189196853033 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Catalina, On 9/6/07, Patrick Linskey wrote: > > > FWIW, I was also seeing an exception complaining about the 'FOR UPDATE > OF' clause. I was surprised by the syntax, as I would have expected it > to say 'FOR UPDATE OF '. I agree with Patrick on this question. According to the db2 manual, the "FOR UPDATE OF" clause is supposed to be followed by a list of column(s). Otherwise, the clause should just be "FOR UPDATE". I looked at the sql generation code and I didn't see where we are supplying any column identifiers. Am I missing something? For reference: http://publib.boulder.ibm.com/infocenter/dzichelp/v2r2/topic/com.ibm.db29.doc.sqlref/xf6a19.htm#xf6a19 Thanks, Kevin -Patrick > > On 9/6/07, catalina wei wrote: > > Hi Patrick, > > That SQL is correct syntax if you are running DB2 UDB version 8.1 or > earlier > > and the isolation level is set pessimistic. > > > > If you are not running the said DB2 version and still seeing "FOR UPDATE > OF" > > string, then we have a problem in DB2Dictionary. > > > > Catalina > > > > > > On 9/6/07, Patrick Linskey wrote: > > > > > > Hi, > > > > > > I'm seeing SQL like so: > > > > > > SELECT t0.ID, t0.VERSN, t0.STRINGFIELD FROM SIMPLEPERSISTENTCLASS t0 > > > FOR UPDATE OF > > > > > > Is this valid DB2 SQL? I'm using a DB2 database that returns SQL08016 > > > from a call to getDatabaseProductVersion(). I'm guessing that the > > > checks for the FOR UPDATE clauses are getting tripped up somewhere. > > > Any suggestions about what it should be for this version of DB2? > > > > > > -Patrick > > > > > > -- > > > Patrick Linskey > > > 202 669 5907 > > > > > > > > -- > Patrick Linskey > 202 669 5907 > ------=_Part_3628_30888589.1189196853033--