ccsminer
Posts: 159
|
Posted: 01/27/2017, 5:55 PM |
|
CCS Forum -
When a query returns a relatively large data set (i.e. 80,000 records+), what is the most efficient
way in CCS to query for that data and display it within a multiple-page (i.e. 50 records/page) grid view?
Thankyou.
- CCSMiner
|
|
|
ccsminer
Posts: 159
|
Posted: 01/28/2017, 1:00 AM |
|
Quote ccsminer:
CCS Forum -
When a query returns a relatively large data set (i.e. 80,000 records+), what is the most efficient
way in CCS to query for that data and display it within a multiple-page (i.e. 50 records/page) grid view?
Thankyou.
- CCSMiner
Should all the records be queried, or only the required amount to display on a given page?
How are some of you doing this for very large data sets when populating a grid view?
Thankyou.
- CCSMiner
|
|
|
eratech
Posts: 513
|
Posted: 02/11/2017, 10:43 PM |
|
@ccsminer - In the connection settings to the DB there is usually a LIMIT setting that CCS uses to only get a limited number of records at once. Then it will use the Navigator and page settings to move through the dataset. In MySQL part of the query will include something like 'LIMIT 30,20' for starting at record 30 and getting the next 20 records (I think).
One of my projects has over a million records in one table, but when we pull out those for a single person then CCS will alter the query to limit to (say) the first 200 for that person and display the first 20, although they might have 500-1000 records. Clicking the 'Next Page' will grab the next page of say, 20 records.
Providing you have a decent index or two (eg: organisation_id and person_id, or maybe a date field) set up so you are not doing a full table read and filter for every query then you should find it quite efficient without much extra work.
Cheers
Eric
_________________
CCS 3/4/5 ASP Classic, VB.NET, PHP
Melbourne, Victoria, Australia |
|
|
ccsminer
Posts: 159
|
Posted: 02/18/2017, 11:15 PM |
|
Thankyou. :)
Quote eratech:
@ccsminer - In the connection settings to the DB there is usually a LIMIT setting that CCS uses to only get a limited number of records at once. Then it will use the Navigator and page settings to move through the dataset. In MySQL part of the query will include something like 'LIMIT 30,20' for starting at record 30 and getting the next 20 records (I think).
One of my projects has over a million records in one table, but when we pull out those for a single person then CCS will alter the query to limit to (say) the first 200 for that person and display the first 20, although they might have 500-1000 records. Clicking the 'Next Page' will grab the next page of say, 20 records.
Providing you have a decent index or two (eg: organisation_id and person_id, or maybe a date field) set up so you are not doing a full table read and filter for every query then you should find it quite efficient without much extra work.
Cheers
Eric
|
|
|
|