Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 45528 invoked from network); 9 Jan 2006 15:41:36 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 9 Jan 2006 15:41:36 -0000 Received: (qmail 31517 invoked by uid 500); 9 Jan 2006 15:41:30 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 31472 invoked by uid 500); 9 Jan 2006 15:41:30 -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 31435 invoked by uid 99); 9 Jan 2006 15:41:30 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 09 Jan 2006 07:41:30 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=HTML_MESSAGE X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [128.100.132.42] (HELO bureau14.utcc.utoronto.ca) (128.100.132.42) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 09 Jan 2006 07:41:28 -0800 Received: from zarar.sis.utoronto.ca ([128.100.105.83] HELO zarar ident: IDENT-NOT-QUERIED [port 4020]) by bureau14.utcc.utoronto.ca with SMTP id <890105-22952>; Mon, 9 Jan 2006 10:40:20 -0500 Message-ID: <005a01c61532$fd207a30$53696480@sis.utoronto.ca> From: "Zarar Siddiqi" To: References: <20060109153515.21475.qmail@web32507.mail.mud.yahoo.com> Subject: Re: parameter map Date: Mon, 9 Jan 2006 10:40:15 -0500 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0057_01C61509.139EC8E0" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2670 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2670 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N This is a multi-part message in MIME format. ------=_NextPart_000_0057_01C61509.139EC8E0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable It might be because java.util.Map and java.util.List are interfaces and = not classes. I think the defaults in this case will work fine (aka: = don't specify anything). You can also use java.util.HashMap as the = parameter class. ----- Original Message -----=20 From: radha rukmani=20 To: user-java@ibatis.apache.org=20 Sent: Monday, January 09, 2006 10:35 AM Subject: parameter map Hi=20 I am trying to pass some parameters into the select statement.=20 My select statement in ibatis, is like this. And i am calling this from the java class, like this. parameterMap.put("transferStatus",TRANSFER_STATUS_PENDING); parameterMap.put("locationStatus",LOCATION_STATUS_PERMANENT); try{ pendingPlates =3D = (List)sqlMap.queryForList("getTransferPendingPlates",parameterMap); }catch(Exception e) Now my pendingPlates list shows an empty list of strings. but if i run = the same query in oracle, i get some result. What am i doing wrong. = Could any one please help Thanks. -------------------------------------------------------------------------= ----- Yahoo! Photos Ring in the New Year with Photo Calendars. Add photos, events, = holidays, whatever. ------=_NextPart_000_0057_01C61509.139EC8E0 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
It might be because java.util.Map and=20 java.util.List are interfaces and not classes.  I think the = defaults in=20 this case will work fine (aka: don't specify anything).  You = can also=20 use java.util.HashMap as the parameter class.
----- Original Message -----
From:=20 radha=20 rukmani
Sent: Monday, January 09, 2006 = 10:35=20 AM
Subject: parameter map

Hi
 
I am trying to pass some parameters into the = select statement.=20
 
My select statement in ibatis, is like this.
<select id=3D"getTransferPendingPlates"=20 parameterClass=3D"java.util.Map" = resultClass=3D"java.util.List">
SELECT
GBL_PLATE_BAR_CODE
FROM GTN_FERT_PLATE
WHERE LOCATION_STATUS=3D#locationStatus#
AND
TRANSFER_STATUS=3D#transferStatus#
</select>
 
And i am = calling this from=20 the java class, like this.
 
  parameterMap.put("transferStatus",TRANSFER_STATUS_PE= NDING);
  parameterMap.put("locationStatus",LOCATION_STATUS_= PERMANENT);
  try{
   pendingPlates=20 =3D=20 = (List)sqlMap.queryForList("getTransferPendingPlates",parameterMap);
&n= bsp; }catch(Exception=20 e)
Now my = pendingPlates list=20 shows an empty list of strings. but if i run the same query in oracle, = i get=20 some result. What am i doing wrong. Could any one please=20 help
 
Thanks.


Yahoo! Photos
Ring in the New Year with Phot= o=20 Calendars
. Add photos, events, holidays,=20 whatever. ------=_NextPart_000_0057_01C61509.139EC8E0--