K
KevinE via AccessMonster.com
Hello,
I'm trying to do a simple average query as set out below:
SELECT [MAIN].Names, Avg([MAIN].Hrs) AS AvgOfHrs, Count([MAIN].Hrs) AS
CountOfHrs
FROM [MAIN]
GROUP BY [MAIN].Names, [Main].ID
ORDER BY [Main].ID;
My problem being that I would like to have all negative numbers register as
zero in the calculation.
Can this be done in a single query?
e.g.
5.0
1.5
2.5
-1.5
-1.0
3.0
Ave = 2.0
many thanks,
Kevin
I'm trying to do a simple average query as set out below:
SELECT [MAIN].Names, Avg([MAIN].Hrs) AS AvgOfHrs, Count([MAIN].Hrs) AS
CountOfHrs
FROM [MAIN]
GROUP BY [MAIN].Names, [Main].ID
ORDER BY [Main].ID;
My problem being that I would like to have all negative numbers register as
zero in the calculation.
Can this be done in a single query?
e.g.
5.0
1.5
2.5
-1.5
-1.0
3.0
Ave = 2.0
many thanks,
Kevin