SQL Snippet: Get Dates for Accruals

More from Ian Grieve, this time a little SQL magic for accruals.