If I run a query that includes an Aggregation function (AVG), is there any way I can get that to display on multiple rows? The query I need would be something like:
SELECT field1, field2, AVG(field2) FROM tMyTable;
The output I need would be something like:
field 1 | field 2 | AVG(field2)
record1 | 1.17 | 1.19
record2 | 1.21 | 1.19
record3 | 1.18 | 1.19
As you can see, I need the average output to be displayed on each and every line. I appreciate that this may be/is an unorthodox approach, however that output format is needed for a charting app that I use.
If there are any methods available then I’d be grateful for your suggestions. Perhaps nesting a second lookup?
1 Answer