You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently a paging query also calculates the total # of rows. This means the query is actually executed twice: once for obtaining the resultset page, and once for calculating the # of rows.
Paging through a resultset therefore is slower than needed, as the count isn't always needed on subsequential pages. It might (some people like to think they're not working with stale data) but in general it's common the # of rows is calculated once, the # of pages is calculated from that and paging through the resultset based on that number is then done by just calculating the rows on page P. It's uncommon users page through all the pages in a resultset (unless there are a low number of pages).
If the query executed is an expensive query, executing it multiple times for no reason can hurt performance, so it should be possible to specify whether the # of rows should be calculated as well or not.
The text was updated successfully, but these errors were encountered:
Currently a paging query also calculates the total # of rows. This means the query is actually executed twice: once for obtaining the resultset page, and once for calculating the # of rows.
Paging through a resultset therefore is slower than needed, as the count isn't always needed on subsequential pages. It might (some people like to think they're not working with stale data) but in general it's common the # of rows is calculated once, the # of pages is calculated from that and paging through the resultset based on that number is then done by just calculating the rows on page P. It's uncommon users page through all the pages in a resultset (unless there are a low number of pages).
If the query executed is an expensive query, executing it multiple times for no reason can hurt performance, so it should be possible to specify whether the # of rows should be calculated as well or not.
The text was updated successfully, but these errors were encountered: