Re: [GENERAL] Count for pagination

2011-04-11 Thread Michael C Rosenstein
Any suggestions on how to get the count of all records that could be returned We use a window function to get the total # of records within each of our paginated queries: SELECT ... ,COUNT(*) OVER() fullRowCount FROM ... WHERE ... ORDER BY ... LIMIT ... OFFSET ...; While there is a

[GENERAL] Count for pagination

2011-04-08 Thread Jason Long
The main search screen of my application has pagination. I am basically running 3 queries with the same where clause. 1. Totals for the entire results(not just the number of rows on the first page) a. 300 ms 2. Subset of the total records on that page. a. 1-2 sec 3. Count of the

[GENERAL] Count for pagination

2011-04-08 Thread Jason Long
The main search screen of my application has pagination. I am basically running 3 queries with the same where clause. 1. Totals for the entire results(not just the number of rows on the first page) a. 300 ms 2. Subset of the total records for one page. a. 1-2 sec 3. Count of the

Re: [GENERAL] Count for pagination

2011-04-08 Thread Stephen Frost
* Jason Long (ja...@octgsoftware.com) wrote: The main search screen of my application has pagination. http://www.depesz.com/index.php/2007/08/29/better-results-paging-in-postgresql-82/ Thanks, Stephen signature.asc Description: Digital signature