Re: Sorting and Pagination in Many-to-Many relationship

2009-09-16 Thread Nishant Neeraj
ote: From: Aristedes Maniatis Subject: Re: Sorting and Pagination in Many-to-Many relationship To: user@cayenne.apache.org Date: Wednesday, 16 September, 2009, 7:22 AM On 16/09/09 6:22 AM, Nishant Neeraj wrote: > A question regarding caching. When we use SQLTemplate or Expression, does the > ob

Re: Sorting and Pagination in Many-to-Many relationship

2009-09-15 Thread Aristedes Maniatis
On 16/09/09 6:22 AM, Nishant Neeraj wrote: A question regarding caching. When we use SQLTemplate or Expression, does the objects gets cached? I mean, these are very frequent used piece of code as soon as user logs in we will show his list of Magazines... if the object is not cached, we may

Re: Sorting and Pagination in Many-to-Many relationship

2009-09-15 Thread Nishant Neeraj
--- On Mon, 14/9/09, Michael Gentry wrote: From: Michael Gentry Subject: Re: Sorting and Pagination in Many-to-Many relationship To: user@cayenne.apache.org Date: Monday, 14 September, 2009, 8:23 PM Hi Nishant, First off, unless your Subscription Type is rather dynamic, you might want to

Re: Sorting and Pagination in Many-to-Many relationship

2009-09-14 Thread Michael Gentry
Hi Nishant, First off, unless your Subscription Type is rather dynamic, you might want to consider using an enum for it (especially if you are using 3.0): http://cayenne.apache.org/doc/modeling-enumerations.html Next, it sounds like what you are wanting is a list of magazines for a given user.

Re: Sorting and Pagination in Many-to-Many relationship

2009-09-13 Thread Nishant Neeraj
the DB relationship model is      http://i30.tinypic.com/jaz4wm.jpg - Nishant --- On Sun, 13/9/09, Nishant Neeraj wrote: From: Nishant Neeraj Subject: Sorting and Pagination in Many-to-Many relationship To: "Cayenne Mailing List" Date: Sunday, 13 September, 2009, 2:25 PM I

Sorting and Pagination in Many-to-Many relationship

2009-09-13 Thread Nishant Neeraj
I am having problem in sorting and paginating  many to many relationship objects. Here is the DB relationship model.  http://i30.tinypic.com/jaz4wm.jpgI want to do Readers.getMagzines() that returns paginated resultset of page size, N. I write a Readers.getMagzine() Method that pulls out List of