The tricky part of this situation is that it is likely Terry wants to page between 25 of the outer records (product line), not 25 products.

A different way of asking: Let's say we are talking about contacts with 1 or more phone numbers, if I display 25 contacts and am using the cfoutput group method, how will I know where to start on the 26th contact, when it may very well be the 87th record?

One solution could be to do a seperate query for the products (or phone numbers) that is based on the product line (or contact) IDs returned by the primary query and then use qoq to display the products or phone numbers with the respective product line or contact.

- Calvin
  ----- Original Message -----
  From: John Beynon
  To: CF-Talk
  Sent: Tuesday, December 30, 2003 11:00 AM
  Subject: RE: Query paging Problem

  You'll need to use Cfloop with startrow and endrow parameters specified to
  display as many records as you want per page. You'll cfparam url.startrow
  (so a default exists the first time you hit the page) to 1 then have a link
  on the page, ie a NEXT button - reloading the page, passing the id of the
  first record on the next page...

  Also, you need to know how many records exist, then how many records per
  page which then will tell you how many pages you'll have.

  -----Original Message-----
  From: Terry Troxel [mailto:[EMAIL PROTECTED]
  Sent: 30 December 2003 15:45
  To: CF-Talk
  Subject: Query paging Problem

  Could someone please give me an example of how to break up query
  results to x number of records to a page ala Google, when you are using
  grouping in your cfoutput tags?

  I am doing a shopping cart and grouping on product lines, then
  nesting a blank cfoutput inside to display all the items within that
  product line.

  Terry Troxel
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to