You intuition is correct, and a calendar table approach should work here:
WITH dates AS (
SELECT date_trunc('day', dt)::date AS dt
FROM generate_series (
'2021-01-01'::timestamp,
'2021-01-31'::timestamp,
'1 day'::interval) dt
)
SELECT d.dt AS Date, t.ID
FROM dates d
LEFT JOIN yourTable t
ON d.dt BETWEEN t.Date1 AND t.Date2;
Demo
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…