Jamroom Logo
Newsletter
Member Spotlight
80284
Illustration.net
"Illustration.net is yet another example of Jamroom's versatility in the world of professional CMS Apps. Created by Oinkba Design, Illustration.net is a social network for artists and buyers which includes a marketplace for Digital and Original Artwork. The site also includes many tools for artist promotions and portfolios with Virtual Walls, Search by Colors and many other custom functions integrated."
Follow Jamroom on Twitter!


dbNumberRows Function Index dbQuery
dbPagedQuery

The dbPagedQuery function is a "paginator" for db results. It does NOT create any of the output, but will return an array consisting of the actual data, and the "prev" and "next" pages, if they exist

  • return: returns array of data
array dbPagedQuery (string $query, int $start, int $count, [string $_ret = 'NUMERIC'], [string $c_query = false])
  • string $query: SQL query to run
  • int $start: Numerical offset (start) of first row to return (default 0)
  • int $count: Number of rows to return
  • string $_ret: Return type for data. This can be any of the valid return types as used by dbQuery().
  • string $c_query: optional Counting Query that will be used in place of primary query to retrieve row count.
 Comments
bigguy, 11/11/09 15:01:29:

The purpose of the "Counting Query" is to return the TOTAL NUMBER OF ROWS that meet your criteria. If your SQL does not have any WHERE conditions, it is faster to grab the total number of rows using dbNumberRows(), and pass in that number - i.e.

$num = dbNumberRows($jamroom_db['band_info']);

Then pass in $num as the $c_query.
You must be logged in to post a comment
Solutions Products Support Community Company
Social Media Platform
Social Networking Software
Musician Website Manager
Community Builder
Jamroom Core
Jamroom Addons
Jamroom Modules
Jamroom Marketplace
Support Forum
Documentation
Support Center
Contact Support
Community Forum
Member Sites
Developers
About Us
Contact Us
Privacy Policy
©2003 - 2012 Talldude Networks, LLC.