  We study stochastic delay differential equations (SDDE) where the
coefficients depend on the moving averages of the state process. As a first
contribution, we provide sufficient conditions under which a linear path
functional of the solution of a SDDE admits a finite-dimensional Markovian
representation. As a second contribution, we show how approximate
finite-dimensional Markovian representations may be constructed when these
conditions are not satisfied, and provide an estimate of the error
corresponding to these approximations. These results are applied to optimal
control and optimal stopping problems for stochastic systems with delay.
