Postgresql – Listing intervals with the most overlaps
I have a table like: create table movement_logs ( id integer NOT NULL, room_id integer NOT NULL, entry_time timestamp NOT NULL, exit_time timestamp, user_id integer NOT NULL ) This models a domain where users enter rooms. This table logs timestamps…