Budgetary policies in a DSGE model with finite horizons