ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <rambabu.pir...@wipro.com>
Subject Thank you Gagner (RE: -------Pagination----Need help)
Date Tue, 25 Jul 2006 12:50:34 GMT


Hi Gagner,

Thank for the reply,

I am using Firebird 1.5.2 database.

You said that you wouldn't recommend the approach mentioned below.

Can you please suggest me the alternate way to send the arguments to the
query.

So that the query should be able to retrive the records between the
specified interval.

 

Thanks n Regards,
================
Rambabu

-----Original Message-----
From: Jerome Gagner [mailto:phpmonkey@gmail.com]
Sent: Tuesday, July 25, 2006 12:22 PM
To: user-java@ibatis.apache.org
Subject: Re: -------Pagination----Need help

What database? You can do it in queryForList and have Ibatis limit it,
but I wouldn't recommend doing it that way.

On 7/24/06, rambabu.piridi@wipro.com <rambabu.piridi@wipro.com> wrote:
>
>
>
>
> Hi,
>
> I have two tables user_info and user_dynamic_info
>
> the following is the table structure
>
> user_info
> =======
> user_id           primarykey
> user_name
> user_password
>
> user_dynamic_info
> =============
> user_id   ForeignKey(user_info)
> property_name
> property_value
>
> I have one bean class which maps the information from these tables to
> one java Object
>
> public class User
> {
>     String userId;
>     List dynamicInfo;
> }
>
>
> Now the table contains 200 records, and I want to retrieve 10 records
> every time when i invoke the select query.
>
> inside the method
>
> public List getProperties(int fromRecord, int recordsPerTransaction) {
>      List list =   SqlMapClient.queryForList("getProperties",null)
> }
>
> It is working fine when the records count is more than 500. But when
> my Db contains lessthan 500 records, the result is unpredictable.
>
> my query is
>
>
> select BASIC.USER_ID,BASIC.USER_PWD,BASIC.USER_NAME EXTENSIN.USER_ID,
> EXTENSIN.PROPERTY_NAME,EXTENSIN.PROPERTY_VALUE from USER_INFO BASIC
> LEFT OUTER JOIN USER_DYNAMIC_INFO EXTENSIN ON
BASIC.USER_ID=EXTENSIN.USER_ID.
>
> is there any way to pass the fromRecord, recordsPerTransaction  to the

> query
>
> Can any one help me in this regard,
>
>
> Thanks n Regards,
> ==============
> Rambabu
>
>  The information contained in this electronic message and any
> attachments to this message are intended for the exclusive use of the
> addressee(s) and may contain proprietary, confidential or privileged
> information. If you are not the intended recipient, you should not
> disseminate, distribute or copy this e-mail. Please notify the sender
> immediately and destroy all copies of this message and any
attachments.
>
>  WARNING: Computer viruses can be transmitted via email. The recipient

> should check this email and any attachments for the presence of
> viruses. The company accepts no liability for any damage caused by any

> virus transmitted by this email.
>
>  www.wipro.com
>


The information contained in this electronic message and any attachments to this message are
intended for the exclusive use of the addressee(s) and may contain proprietary, confidential
or privileged information. If you are not the intended recipient, you should not disseminate,
distribute or copy this e-mail. Please notify the sender immediately and destroy all copies
of this message and any attachments.

WARNING: Computer viruses can be transmitted via email. The recipient should check this email
and any attachments for the presence of viruses. The company accepts no liability for any
damage caused by any virus transmitted by this email.

www.wipro.com

Mime
View raw message