It sounds quite complicated.
I'm not at all sure if this will work for you or for the setup of your data,
but it sounds to me like it would be beneficial to join your data to an
external table which is just a single column of all possible days
(as far in the past and future as you would like).
That way, you would always have all the days you need regardless of
If you would like to pursue this, please describe your datasource types
and post a small sample of fake data in the format of your true set.