  A general continuous mean-variance problem is considered for a diffusion
controlled process where the reward functional has an integral and a
terminal-time component. The problem is transformed into a superposition of a
static and a dynamic optimization problem. The value function of the latter can
be considered as the solution to a degenerate HJB equation either in viscosity
or in Sobolev sense (after a regularization) under suitable assumptions and
with implications with regards to the optimality of strategies. There is a
useful interplay between the two approaches -- viscosity and Sobolev.
