AVG(a.preco_total / DATEDIFF(a.data_fim, a.data_inicio)) AS media_preco_aluguel, MAX(a.preco_total / DATEDIFF(a.data_fim, a.data_inicio)) AS max_preco_dia, MIN(a ...
Understanding the MySQL DATEDIFF Function 📆 In the world of MySQL, handling date differences is a breeze with the DATEDIFF function. It computes the difference between two dates and returns the ...