Untitled

mail@pastecode.io avatar
unknown
mysql
2 years ago
311 B
2
Indexable
Never
SELECT 
      avg(relative_speed) as avg_speed
      
FROM   `laps`
      INNER JOIN `track_variations`
              ON `track_variation_id` = `track_variations`.`id`
      
WHERE  `length` > 0
      AND `track_variations`.`flagged` = 0
      AND `wet` = 0
      AND `novice` = 0
      AND `laps`.`flagged` = 0