Skip to main content

New answers tagged

0 votes
Accepted

In PostgreSQL how to get the hourly minimum of a value using a window function?

In this query: SELECT to_char("time", 'YYYY-MM-DD HH'), AVG("Temperature_deg_in_C") FROM "measurements" WHERE "time" BETWEEN '2024-11-01' AND '2024-12-01' GROUP ...
bobflux's user avatar
  • 1,691
-1 votes

In PostgreSQL how to get the hourly minimum of a value using a window function?

PLPgSQL query using windows function: SELECT to_char(time, 'YYYY-MM-DD HH'), ROUND( AVG(temperature_deg_in_c) OVER ( PARTITION BY to_char("time", 'YYYY-MM-DD HH'...
ArtBindu's user avatar
  • 101

Top 50 recent answers are included