avg(a.flight_distance) as average_distance
count(distance) as flight_distance
group by 1,2,3
group by 1,2
order by 1,2
I have to find the average total distance flown by day of week and month .Cn anyone tell me the error in my code?
Hint: It's not count(distance) because you're not counting the number of distance, your calculating the total sum of all the distance
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.