I have users entering parameters which are picked up by a query to select records and display in a report with a chart. The chart is only part of the report and is small. I need to limit the data points to a maximum of about 15 but it is possible to get up to 1500 records.
THE PROBLEM:
Therefore, I need to group the records but the grouping must be dynamic because it must reflect the nature of all the data. So...... obviously I can't just group the first 100 records then the second 100 records and soforth since the total amount of records may be less than 100 so my chart would get only 1 data point.
THE QUESTION:
How do I write my query (which uses only 2 fields to creat the chart)so that it will array the data and segment it into 15 groups then average or in someway group those records so that in the end it displays only 15 data points, thus, representing all the records when I make my chart, no matter how many records were actually selected? :
THE PROBLEM:
Therefore, I need to group the records but the grouping must be dynamic because it must reflect the nature of all the data. So...... obviously I can't just group the first 100 records then the second 100 records and soforth since the total amount of records may be less than 100 so my chart would get only 1 data point.
THE QUESTION:
How do I write my query (which uses only 2 fields to creat the chart)so that it will array the data and segment it into 15 groups then average or in someway group those records so that in the end it displays only 15 data points, thus, representing all the records when I make my chart, no matter how many records were actually selected? :