Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 77305 invoked from network); 7 Feb 2006 08:22:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 7 Feb 2006 08:22:37 -0000 Received: (qmail 81303 invoked by uid 500); 7 Feb 2006 08:22:30 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 81287 invoked by uid 500); 7 Feb 2006 08:22:29 -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 81274 invoked by uid 99); 7 Feb 2006 08:22:29 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 Feb 2006 00:22:29 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [196.35.77.56] (HELO mfw1.busgateway.is.co.za) (196.35.77.56) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 Feb 2006 00:22:28 -0800 Received: from BG-SMTP02.he.businessgateway.co.za (Not Verified[196.35.61.87]) by mfw1.busgateway.is.co.za with NetIQ MailMarshal (v5.5.6.7) id ; Tue, 07 Feb 2006 10:24:11 +0200 Received: from meindert ([165.146.165.27]) by BG-SMTP02.he.businessgateway.co.za with Microsoft SMTPSVC(6.0.3790.1830); Tue, 7 Feb 2006 10:22:03 +0200 From: "Meindert" To: Subject: RE: dynamic insert question Date: Tue, 7 Feb 2006 10:22:19 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset="windows-1250" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook, Build 11.0.5510 Thread-Index: AcYrt18uBqF5FoHcSZWpPeBRh8ToKwAA1VrAAAEwIoA= In-Reply-To: X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 Message-ID: X-OriginalArrivalTime: 07 Feb 2006 08:22:03.0543 (UTC) FILETIME=[9339E270:01C62BBF] X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N He already said that ## didn't work (because it is a select and not a parameter?) MEINDERT HOVING -----Original Message----- From: Yusuf [mailto:Yusuf@ekalife.co.id] Sent: 07 February 2006 09:50 AM To: user-java@ibatis.apache.org Subject: RE: dynamic insert question Well I think the solution is not using $$ but ## select #family#,partnum,parttype,'N' from cto.partinfo -----Original Message----- From: stevenlou@gmail.com [mailto:stevenlou@gmail.com] Sent: Tuesday, February 07, 2006 2:19 PM To: user-java@ibatis.apache.org Subject: Re: dynamic insert question Hi, Thanks for your promp reply, but the question isn't in the "domain", this part is working. The problem is when the select result(first step) insert into the target table, seems it cann't know the "family" type, so that it can't insert. Actually I want the select is like this: select $family$,partnum,parttype,'N' from cto.partinfo where ...... And I will input one parameter like '8848' (or others) to family. What's solution for it? Thanks Steven On 2/7/06, Yusuf < Yusuf@ekalife.co.id > wrote: Hi, Does the "PartVO" object have a property named "domain" and it's a list or an array? -----Original Message----- From: stevenlou@gmail.com [mailto: stevenlou@gmail.com ] Sent: Tuesday, February 07, 2006 1:33 PM To: user-java@ibatis.apache.org Subject: dynamic insert question Dear all, I want insert the table via one dynamic select, the "PartVO" is one object and it has "family" attribute, and it's type is "String", #domain[ ]# But it cause following error,seems the select can't get string value for "family" column, but in the "PartVO" object, I already defined its type is "String", and others are working(I use DB2 database): Caused by: COM.ibm.db2.jdbc.DB2Exception: [IBM][CLI Driver][DB2/NT] SQL0408N A value is not compatible with the data type of its assignment target. Target name is "FAMILY". SQLSTATE=42821 How can I make this function working? Thanks so much for your warm-heated help! Steven -- No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.375 / Virus Database: 267.15.2/252 - Release Date: 06/02/2006 -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.375 / Virus Database: 267.15.2/252 - Release Date: 06/02/2006